http://bugs.winehq.org/show_bug.cgi?id=20964
--- Comment #8 from Andreas Fink andreas.fink85@gmail.com 2010-08-21 17:22:57 --- Created an attachment (id=30275) --> (http://bugs.winehq.org/attachment.cgi?id=30275) Simple patch which reregisters the icons
This patch adds the ability for wine system tray icons (as for example uTorrent) to be readded to the systemtray if the systemtray is restarted.
There are at least 2 limitations/problems: 1. An X11-systemtray has to be running in the first place (otherwise wine is adding the icon to the internal system tray, and the icon will never be added to the X11-systemtray)
2. XSelectInput(display, root_window, StructureNotifyMask) in the file x11drv_main.c is called for every X11 display wine opens, but it only needs to be called for the systemtray controlling one (I guess explorer.exe, but I did not dig deep enough through the wine code). Anyway this does not change any behaviour, except that we are calling the function X11DRV_DockAllTrayIcons(void) where the systray icon_list is empty.
Another thing that maybe is not considering the coding guidelines is adding the function prototype X11DRV_DockAllTrayIcons(void) to dlls/winex11.drv/x11drv.h but otherwise I did not know how to let the systray know, that a new systemtray did register (in event.c we get the notification).