Module: wine Branch: master Commit: 13820b6f948b4447ed8d73e2e6975155441a8653 URL: http://source.winehq.org/git/wine.git/?a=commit;h=13820b6f948b4447ed8d73e2e6...
Author: Henri Verbeet hverbeet@codeweavers.com Date: Mon Aug 13 11:39:41 2012 +0200
winex11: Don't set MWM decorations either for fullscreen virtual desktops.
---
dlls/winex11.drv/desktop.c | 5 +++++ dlls/winex11.drv/window.c | 5 +++-- dlls/winex11.drv/x11drv.h | 1 + 3 files changed, 9 insertions(+), 2 deletions(-)
diff --git a/dlls/winex11.drv/desktop.c b/dlls/winex11.drv/desktop.c index c75c54c..66b1e11 100644 --- a/dlls/winex11.drv/desktop.c +++ b/dlls/winex11.drv/desktop.c @@ -203,6 +203,11 @@ static BOOL CALLBACK update_windows_on_desktop_resize( HWND hwnd, LPARAM lparam return TRUE; }
+BOOL is_desktop_fullscreen(void) +{ + return screen_width == max_width && screen_height == max_height; +} + static void update_desktop_fullscreen( unsigned int width, unsigned int height) { Display *display = thread_display(); diff --git a/dlls/winex11.drv/window.c b/dlls/winex11.drv/window.c index b202586..46e2cdb 100644 --- a/dlls/winex11.drv/window.c +++ b/dlls/winex11.drv/window.c @@ -1063,8 +1063,9 @@ static void set_mwm_hints( Display *display, struct x11drv_win_data *data, DWORD
if (data->hwnd == GetDesktopWindow()) { - mwm_hints.decorations = MWM_DECOR_TITLE | MWM_DECOR_BORDER | MWM_DECOR_MENU | MWM_DECOR_MINIMIZE; - mwm_hints.functions = MWM_FUNC_MOVE | MWM_FUNC_MINIMIZE | MWM_FUNC_CLOSE; + if (is_desktop_fullscreen()) mwm_hints.decorations = 0; + else mwm_hints.decorations = MWM_DECOR_TITLE | MWM_DECOR_BORDER | MWM_DECOR_MENU | MWM_DECOR_MINIMIZE; + mwm_hints.functions = MWM_FUNC_MOVE | MWM_FUNC_MINIMIZE | MWM_FUNC_CLOSE; } else { diff --git a/dlls/winex11.drv/x11drv.h b/dlls/winex11.drv/x11drv.h index 32d7772..59bc672 100644 --- a/dlls/winex11.drv/x11drv.h +++ b/dlls/winex11.drv/x11drv.h @@ -649,6 +649,7 @@ struct x11drv_mode_info
extern void X11DRV_init_desktop( Window win, unsigned int width, unsigned int height ) DECLSPEC_HIDDEN; extern void X11DRV_resize_desktop(unsigned int width, unsigned int height) DECLSPEC_HIDDEN; +BOOL is_desktop_fullscreen(void) DECLSPEC_HIDDEN; extern void X11DRV_Settings_AddDepthModes(void) DECLSPEC_HIDDEN; extern void X11DRV_Settings_AddOneMode(unsigned int width, unsigned int height, unsigned int bpp, unsigned int freq) DECLSPEC_HIDDEN; unsigned int X11DRV_Settings_GetModeCount(void) DECLSPEC_HIDDEN;