You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
On Windows when you create an app with Tauri with a system tray icon and run it, the icon is visible on the system tray in the taskbar. When you restart explorer, the system tray icon disappears. This is problematic when your app runs in the background with no visible window and where the window can only be made visible via the system tray menu. So when explorer restarts, the app is still running but you cannot access it anymore.
The problem is probably caused by Tauri not handling the TaskbarCreated event to register the icon again for the new task bar.
Another problem related to restarting explorer is when you have set skip_taskbar to true and then restart explorer, suddenly the Tauri app is visible on the taskbar.
On Windows, some applications restart explorer when an update is installed in the background. Therefore it is necessary that Tauri supports this and re-registers the system tray icon when this happens and also handles the skip_taskbar properly.
Reproduction
Create a simple Tauri app with one window with a system tray icon and with a system tray menu where you can close the app and set skip_taskbar to true on the window.
Run the app and notice the system tray icon.
Now restart explorer.exe. You can do this via Task Manager. Run Task Manager, search for "Windows Explorer", select it, and press the restart button at the bottom right.
Notice that Windows Explorer restarts and there is no system tray icon of the Tauri app anymore. Also notice that the app is visible again on the task bar.
Expected behavior
When you have a Tauri app with a system tray icon and where skip_taskbar is set to true, restarting explorer.exe should still show the system tray icon and also it should not make the app visible on the taskbar.
Describe the bug
On Windows when you create an app with Tauri with a system tray icon and run it, the icon is visible on the system tray in the taskbar. When you restart explorer, the system tray icon disappears. This is problematic when your app runs in the background with no visible window and where the window can only be made visible via the system tray menu. So when explorer restarts, the app is still running but you cannot access it anymore.
The problem is probably caused by Tauri not handling the TaskbarCreated event to register the icon again for the new task bar.
More info about the event can be found here:
https://docs.microsoft.com/en-us/windows/win32/shell/taskbar#taskbar-creation-notification
Another problem related to restarting explorer is when you have set skip_taskbar to true and then restart explorer, suddenly the Tauri app is visible on the taskbar.
On Windows, some applications restart explorer when an update is installed in the background. Therefore it is necessary that Tauri supports this and re-registers the system tray icon when this happens and also handles the skip_taskbar properly.
Reproduction
Create a simple Tauri app with one window with a system tray icon and with a system tray menu where you can close the app and set skip_taskbar to true on the window.
Run the app and notice the system tray icon.
Now restart explorer.exe. You can do this via Task Manager. Run Task Manager, search for "Windows Explorer", select it, and press the restart button at the bottom right.
Notice that Windows Explorer restarts and there is no system tray icon of the Tauri app anymore. Also notice that the app is visible again on the task bar.
Expected behavior
When you have a Tauri app with a system tray icon and where skip_taskbar is set to true, restarting explorer.exe should still show the system tray icon and also it should not make the app visible on the taskbar.
Platform and versions
Stack trace
No response
Additional context
No response
The text was updated successfully, but these errors were encountered: