mirror of
https://github.com/YACReader/yacreader
synced 2025-05-28 03:10:27 -04:00
Disabled minimize to system tray for now.
App icon needs some work to look ok in Windows 10 system tray and macos is not ready yet to fully support this.
This commit is contained in:
parent
a8655b1037
commit
6faea2b5a7
@ -139,11 +139,13 @@ void LibraryWindow::setupUI()
|
||||
else
|
||||
//if(settings->value(USE_OPEN_GL).toBool() == false)
|
||||
showMaximized();
|
||||
|
||||
trayIcon.setIcon(QApplication::windowIcon());
|
||||
trayIcon.show();
|
||||
connect(&trayIcon, SIGNAL(activated(QSystemTrayIcon::ActivationReason)),
|
||||
this, SLOT(trayActivation(QSystemTrayIcon::ActivationReason)));
|
||||
}
|
||||
/* //disabled until icons are ready and macos native code is done
|
||||
trayIcon.setIcon(QApplication::windowIcon());
|
||||
trayIcon.show();
|
||||
connect(&trayIcon, SIGNAL(activated(QSystemTrayIcon::ActivationReason)),
|
||||
this, SLOT(trayActivation(QSystemTrayIcon::ActivationReason)));
|
||||
}
|
||||
}
|
||||
|
||||
void LibraryWindow::trayActivation(QSystemTrayIcon::ActivationReason reason)
|
||||
@ -157,6 +159,7 @@ void LibraryWindow::trayActivation(QSystemTrayIcon::ActivationReason reason)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
void LibraryWindow::changeEvent(QEvent *event)
|
||||
{
|
||||
if (event->type() == QEvent::WindowStateChange && isMinimized())
|
||||
@ -167,7 +170,7 @@ void LibraryWindow::changeEvent(QEvent *event)
|
||||
{
|
||||
QMainWindow::changeEvent(event);
|
||||
}
|
||||
}
|
||||
}*/
|
||||
|
||||
void LibraryWindow::doLayout()
|
||||
{
|
||||
|
@ -385,7 +385,7 @@ public slots:
|
||||
void checkMaxNumLibraries();
|
||||
void showErrorUpgradingLibrary(const QString & path);
|
||||
|
||||
void changeEvent(QEvent *event);
|
||||
//void changeEvent(QEvent *event);
|
||||
|
||||
private:
|
||||
//fullscreen mode in Windows for preventing this bug: QTBUG-41309 https://bugreports.qt.io/browse/QTBUG-41309
|
||||
@ -396,7 +396,7 @@ private:
|
||||
QSystemTrayIcon trayIcon;
|
||||
|
||||
private slots:
|
||||
void trayActivation(QSystemTrayIcon::ActivationReason reason);
|
||||
//void trayActivation(QSystemTrayIcon::ActivationReason reason);
|
||||
};
|
||||
|
||||
#endif
|
||||
|
Loading…
Reference in New Issue
Block a user