mirror of
https://github.com/Chatterino/chatterino2.git
synced 2024-11-13 19:49:51 +01:00
37 lines
600 B
C++
37 lines
600 B
C++
#ifndef WINDOWS_H
|
|
#define WINDOWS_H
|
|
|
|
#include "mainwindow.h"
|
|
|
|
#include <QMutex>
|
|
|
|
class Windows
|
|
{
|
|
public:
|
|
static void layoutVisibleChatWidgets(Channel *channel = NULL);
|
|
static void repaintVisibleChatWidgets(Channel *channel = NULL);
|
|
|
|
static MainWindow &
|
|
getMainWindow()
|
|
{
|
|
windowMutex.lock();
|
|
if (mainWindow == NULL) {
|
|
mainWindow = new MainWindow();
|
|
}
|
|
windowMutex.unlock();
|
|
|
|
return *mainWindow;
|
|
}
|
|
|
|
private:
|
|
Windows()
|
|
{
|
|
}
|
|
|
|
static QMutex windowMutex;
|
|
|
|
static MainWindow *mainWindow;
|
|
};
|
|
|
|
#endif // WINDOWS_H
|