Fix systray icon sometimes not appearing after login
This commit is contained in:
@@ -212,6 +212,12 @@ namespace system_tray {
|
|||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Wait for the shell to be initialized before registering the tray icon.
|
||||||
|
// This ensures the tray icon works reliably after a logoff/logon cycle.
|
||||||
|
while (GetShellWindow() == nullptr) {
|
||||||
|
Sleep(1000);
|
||||||
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
if (tray_init(&tray) < 0) {
|
if (tray_init(&tray) < 0) {
|
||||||
|
|||||||
Reference in New Issue
Block a user