explorer: Set layered style on systray icons before calling into the driver.
Fixes a regression introduced by b5c57b9a62
,
which broke the systray integration outside of virtual desktops on some
DEs like XFCE.
Signed-off-by: Gabriel Ivăncescu <gabrielopcode@gmail.com>
This commit is contained in:
parent
223292da02
commit
8a71a4a304
1 changed files with 16 additions and 6 deletions
|
@ -619,13 +619,23 @@ static BOOL show_icon(struct icon *icon)
|
|||
|
||||
if (icon->display != ICON_DISPLAY_HIDDEN) return TRUE; /* already displayed */
|
||||
|
||||
if (!enable_taskbar && NtUserMessageCall( icon->window, WINE_SYSTRAY_DOCK_INSERT, icon_cx, icon_cy,
|
||||
icon, NtUserSystemTrayCall, FALSE ))
|
||||
if (!enable_taskbar)
|
||||
{
|
||||
icon->display = ICON_DISPLAY_DOCKED;
|
||||
icon->layered = TRUE;
|
||||
SetWindowLongW( icon->window, GWL_EXSTYLE, GetWindowLongW( icon->window, GWL_EXSTYLE ) | WS_EX_LAYERED );
|
||||
SendMessageW( icon->window, WM_SIZE, SIZE_RESTORED, MAKELONG( icon_cx, icon_cy ) );
|
||||
DWORD old_exstyle = GetWindowLongW( icon->window, GWL_EXSTYLE );
|
||||
|
||||
/* make sure it is layered before calling into the driver */
|
||||
SetWindowLongW( icon->window, GWL_EXSTYLE, old_exstyle | WS_EX_LAYERED );
|
||||
paint_layered_icon( icon );
|
||||
|
||||
if (!NtUserMessageCall( icon->window, WINE_SYSTRAY_DOCK_INSERT, icon_cx, icon_cy,
|
||||
icon, NtUserSystemTrayCall, FALSE ))
|
||||
SetWindowLongW( icon->window, GWL_EXSTYLE, old_exstyle );
|
||||
else
|
||||
{
|
||||
icon->display = ICON_DISPLAY_DOCKED;
|
||||
icon->layered = TRUE;
|
||||
SendMessageW( icon->window, WM_SIZE, SIZE_RESTORED, MAKELONG( icon_cx, icon_cy ) );
|
||||
}
|
||||
}
|
||||
systray_add_icon( icon );
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue