Fix Xlib locking in create_desktop.

This commit is contained in:
Mike Hearn 2004-12-27 17:03:15 +00:00 committed by Alexandre Julliard
parent 737e67b17b
commit 9b98d3d3d8
1 changed files with 3 additions and 1 deletions

View File

@ -744,10 +744,12 @@ void X11DRV_register_window( Display *display, HWND hwnd, struct x11drv_win_data
static void create_desktop( Display *display, WND *wndPtr )
{
X11DRV_WND_DATA *data = wndPtr->pDriverData;
VisualID visualid;
wine_tsx11_lock();
winContext = XUniqueContext();
XInternAtoms( display, (char **)atom_names, NB_XATOMS - FIRST_XATOM, False, X11DRV_Atoms );
visualid = XVisualIDFromVisual(visual);
wine_tsx11_unlock();
whole_window_atom = MAKEINTATOMA( GlobalAddAtomA( "__wine_x11_whole_window" ));
@ -759,7 +761,7 @@ static void create_desktop( Display *display, WND *wndPtr )
SetPropA( wndPtr->hwndSelf, whole_window_atom, (HANDLE)root_window );
SetPropA( wndPtr->hwndSelf, client_window_atom, (HANDLE)root_window );
SetPropA( wndPtr->hwndSelf, "__wine_x11_visual_id", (HANDLE)XVisualIDFromVisual(visual) );
SetPropA( wndPtr->hwndSelf, "__wine_x11_visual_id", (HANDLE)visualid );
X11DRV_InitClipboard();