Commit 8f4c007f authored by Alexandre Julliard's avatar Alexandre Julliard

Fixed desktop window structure initialization.

parent 502d83b1
...@@ -586,7 +586,7 @@ void X11DRV_register_window( Display *display, HWND hwnd, struct x11drv_win_data ...@@ -586,7 +586,7 @@ void X11DRV_register_window( Display *display, HWND hwnd, struct x11drv_win_data
/********************************************************************** /**********************************************************************
* create_desktop * create_desktop
*/ */
static void create_desktop( Display *display, WND *wndPtr ) static void create_desktop( Display *display, WND *wndPtr, CREATESTRUCTA *cs )
{ {
X11DRV_WND_DATA *data = wndPtr->pDriverData; X11DRV_WND_DATA *data = wndPtr->pDriverData;
...@@ -604,11 +604,13 @@ static void create_desktop( Display *display, WND *wndPtr ) ...@@ -604,11 +604,13 @@ static void create_desktop( Display *display, WND *wndPtr )
wine_tsx11_unlock(); wine_tsx11_unlock();
data->whole_window = data->client_window = root_window; data->whole_window = data->client_window = root_window;
data->whole_rect = data->client_rect = wndPtr->rectWindow;
SetPropA( wndPtr->hwndSelf, "__wine_x11_whole_window", (HANDLE)root_window ); SetPropA( wndPtr->hwndSelf, "__wine_x11_whole_window", (HANDLE)root_window );
SetPropA( wndPtr->hwndSelf, "__wine_x11_client_window", (HANDLE)root_window ); SetPropA( wndPtr->hwndSelf, "__wine_x11_client_window", (HANDLE)root_window );
SetPropA( wndPtr->hwndSelf, "__wine_x11_visual_id", (HANDLE)XVisualIDFromVisual(visual) ); SetPropA( wndPtr->hwndSelf, "__wine_x11_visual_id", (HANDLE)XVisualIDFromVisual(visual) );
SendMessageW( wndPtr->hwndSelf, WM_NCCREATE, 0, (LPARAM)cs );
if (root_window != DefaultRootWindow(display)) X11DRV_create_desktop_thread(); if (root_window != DefaultRootWindow(display)) X11DRV_create_desktop_thread();
} }
...@@ -816,8 +818,7 @@ BOOL X11DRV_CreateWindow( HWND hwnd, CREATESTRUCTA *cs, BOOL unicode ) ...@@ -816,8 +818,7 @@ BOOL X11DRV_CreateWindow( HWND hwnd, CREATESTRUCTA *cs, BOOL unicode )
if (!wndPtr->parent) if (!wndPtr->parent)
{ {
SendMessageW( hwnd, WM_NCCREATE, 0, (LPARAM)cs ); create_desktop( display, wndPtr, cs );
create_desktop( display, wndPtr );
WIN_ReleaseWndPtr( wndPtr ); WIN_ReleaseWndPtr( wndPtr );
return TRUE; return TRUE;
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment