summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rwxr-xr-x[-rw-r--r--]gui/ui.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/gui/ui.cpp b/gui/ui.cpp
index 31bce40b..ffdbf867 100644..100755
--- a/gui/ui.cpp
+++ b/gui/ui.cpp
@@ -548,7 +548,9 @@ void MainWindow::ensure_tray()
void MainWindow::restore_from_tray(QSystemTrayIcon::ActivationReason)
{
show();
- setWindowState(Qt::WindowNoState);
+ setWindowState( (windowState() & ~Qt::WindowMinimized) | Qt::WindowActive);
+ raise(); // for MacOS
+ activateWindow(); // for Windows
}
void MainWindow::changeEvent(QEvent* e)