# include <QMainWindow>
#endif
+#ifdef Q_WS_WIN
+# include <windows.h>
+#endif
+
#include <QSystemTrayIcon>
#include "qtui.h"
-#include "sessionsettings.h"
#include "titlesetter.h"
+#include "uisettings.h"
class ActionCollection;
class BufferView;
inline SystemTray *systemTray() const;
- virtual bool event(QEvent *event);
+ bool event(QEvent *event);
static void flagRemoteCoreOnly(QObject *object) { object->setProperty("REMOTE_CORE_ONLY", true); }
static bool isRemoteCoreOnly(QObject *object) { return object->property("REMOTE_CORE_ONLY").toBool(); }
void saveStateToSessionSettings(SessionSettings &s);
void showStatusBarMessage(const QString &message);
+ void toggleMinimizedToTray();
+
+ //! Bring window to front and focus it
+ void forceActivated();
+
protected:
void closeEvent(QCloseEvent *event);
- virtual void changeEvent(QEvent *event);
+ void changeEvent(QEvent *event);
protected slots:
void connectedToCore();
void updateLagIndicator(int lag = -1);
void disconnectedFromCore();
void setDisconnectedState();
- void systrayActivated(QSystemTrayIcon::ActivationReason);
private slots:
void addBufferView(int bufferViewConfigId);
void setupToolBars();
void updateIcon();
- void hideToTray();
- void toggleMinimizedToTray();
void enableMenus();
+ void hideToTray();
+
SystemTray *_systemTray;
QList<BufferViewDock *> _bufferViews;
QWidget *_awayLog;
friend class QtUi;
+
+#ifdef Q_WS_WIN
+ DWORD dwTickCount;
+#endif
};
SystemTray *MainWin::systemTray() const {