mirror of
https://github.com/bggRGjQaUbCoE/PiliPlus.git
synced 2026-04-21 11:22:16 +08:00
custom show tray icon
Closes #1569 Signed-off-by: bggRGjQaUbCoE <githubaccount56556@proton.me>
This commit is contained in:
@@ -45,8 +45,10 @@ class _MainAppState extends State<MainApp>
|
||||
windowManager
|
||||
..addListener(this)
|
||||
..setPreventClose(true);
|
||||
trayManager.addListener(this);
|
||||
_handleTray();
|
||||
if (_mainController.showTrayIcon) {
|
||||
trayManager.addListener(this);
|
||||
_handleTray();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -131,7 +133,7 @@ class _MainAppState extends State<MainApp>
|
||||
|
||||
@override
|
||||
void onWindowClose() {
|
||||
if (_mainController.minimizeOnExit) {
|
||||
if (_mainController.showTrayIcon && _mainController.minimizeOnExit) {
|
||||
windowManager.hide();
|
||||
_onHideWindow();
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user