Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
313157a0
Commit
313157a0
authored
Sep 24, 2012
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
winex11: Add window data structure locking to the remaining entry points.
parent
b515beb4
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
10 additions
and
23 deletions
+10
-23
desktop.c
dlls/winex11.drv/desktop.c
+2
-1
window.c
dlls/winex11.drv/window.c
+8
-21
x11drv.h
dlls/winex11.drv/x11drv.h
+0
-1
No files found.
dlls/winex11.drv/desktop.c
View file @
313157a0
...
@@ -177,7 +177,7 @@ static BOOL CALLBACK update_windows_on_desktop_resize( HWND hwnd, LPARAM lparam
...
@@ -177,7 +177,7 @@ static BOOL CALLBACK update_windows_on_desktop_resize( HWND hwnd, LPARAM lparam
struct
desktop_resize_data
*
resize_data
=
(
struct
desktop_resize_data
*
)
lparam
;
struct
desktop_resize_data
*
resize_data
=
(
struct
desktop_resize_data
*
)
lparam
;
int
mask
=
0
;
int
mask
=
0
;
if
(
!
(
data
=
X11DRV_
get_win_data
(
hwnd
)))
return
TRUE
;
if
(
!
(
data
=
get_win_data
(
hwnd
)))
return
TRUE
;
/* update the full screen state */
/* update the full screen state */
update_net_wm_states
(
data
);
update_net_wm_states
(
data
);
...
@@ -193,6 +193,7 @@ static BOOL CALLBACK update_windows_on_desktop_resize( HWND hwnd, LPARAM lparam
...
@@ -193,6 +193,7 @@ static BOOL CALLBACK update_windows_on_desktop_resize( HWND hwnd, LPARAM lparam
XReconfigureWMWindow
(
data
->
display
,
data
->
whole_window
,
XReconfigureWMWindow
(
data
->
display
,
data
->
whole_window
,
DefaultScreen
(
data
->
display
),
mask
,
&
changes
);
DefaultScreen
(
data
->
display
),
mask
,
&
changes
);
}
}
release_win_data
(
data
);
if
(
hwnd
==
GetForegroundWindow
())
clip_fullscreen_window
(
hwnd
,
TRUE
);
if
(
hwnd
==
GetForegroundWindow
())
clip_fullscreen_window
(
hwnd
,
TRUE
);
return
TRUE
;
return
TRUE
;
}
}
...
...
dlls/winex11.drv/window.c
View file @
313157a0
...
@@ -1671,24 +1671,6 @@ void release_win_data( struct x11drv_win_data *data )
...
@@ -1671,24 +1671,6 @@ void release_win_data( struct x11drv_win_data *data )
/***********************************************************************
/***********************************************************************
* X11DRV_get_win_data
*
* Return the X11 data structure associated with a window.
*/
struct
x11drv_win_data
*
X11DRV_get_win_data
(
HWND
hwnd
)
{
struct
x11drv_win_data
*
data
=
get_win_data
(
hwnd
);
if
(
data
)
{
release_win_data
(
data
);
if
(
GetWindowThreadProcessId
(
hwnd
,
NULL
)
!=
GetCurrentThreadId
())
data
=
NULL
;
}
return
data
;
}
/***********************************************************************
* X11DRV_create_win_data
* X11DRV_create_win_data
*
*
* Create an X11 data window structure for an existing window.
* Create an X11 data window structure for an existing window.
...
@@ -1882,7 +1864,6 @@ void CDECL X11DRV_GetDC( HDC hdc, HWND hwnd, HWND top, const RECT *win_rect,
...
@@ -1882,7 +1864,6 @@ void CDECL X11DRV_GetDC( HDC hdc, HWND hwnd, HWND top, const RECT *win_rect,
const
RECT
*
top_rect
,
DWORD
flags
)
const
RECT
*
top_rect
,
DWORD
flags
)
{
{
struct
x11drv_escape_set_drawable
escape
;
struct
x11drv_escape_set_drawable
escape
;
struct
x11drv_win_data
*
data
=
X11DRV_get_win_data
(
hwnd
);
HWND
parent
;
HWND
parent
;
escape
.
code
=
X11DRV_SET_DRAWABLE
;
escape
.
code
=
X11DRV_SET_DRAWABLE
;
...
@@ -1897,10 +1878,13 @@ void CDECL X11DRV_GetDC( HDC hdc, HWND hwnd, HWND top, const RECT *win_rect,
...
@@ -1897,10 +1878,13 @@ void CDECL X11DRV_GetDC( HDC hdc, HWND hwnd, HWND top, const RECT *win_rect,
if
(
top
==
hwnd
)
if
(
top
==
hwnd
)
{
{
struct
x11drv_win_data
*
data
=
get_win_data
(
hwnd
);
escape
.
drawable
=
data
?
data
->
whole_window
:
X11DRV_get_whole_window
(
hwnd
);
escape
.
drawable
=
data
?
data
->
whole_window
:
X11DRV_get_whole_window
(
hwnd
);
/* special case: when repainting the root window, clip out top-level windows */
/* special case: when repainting the root window, clip out top-level windows */
if
(
data
&&
data
->
whole_window
==
root_window
)
escape
.
mode
=
ClipByChildren
;
if
(
data
&&
data
->
whole_window
==
root_window
)
escape
.
mode
=
ClipByChildren
;
release_win_data
(
data
);
}
}
else
else
{
{
...
@@ -2372,8 +2356,11 @@ LRESULT CDECL X11DRV_WindowMessage( HWND hwnd, UINT msg, WPARAM wp, LPARAM lp )
...
@@ -2372,8 +2356,11 @@ LRESULT CDECL X11DRV_WindowMessage( HWND hwnd, UINT msg, WPARAM wp, LPARAM lp )
X11DRV_resize_desktop
(
LOWORD
(
lp
),
HIWORD
(
lp
)
);
X11DRV_resize_desktop
(
LOWORD
(
lp
),
HIWORD
(
lp
)
);
return
0
;
return
0
;
case
WM_X11DRV_SET_CURSOR
:
case
WM_X11DRV_SET_CURSOR
:
if
((
data
=
X11DRV_get_win_data
(
hwnd
))
&&
data
->
whole_window
)
if
((
data
=
get_win_data
(
hwnd
)))
set_window_cursor
(
data
->
whole_window
,
(
HCURSOR
)
lp
);
{
if
(
data
->
whole_window
)
set_window_cursor
(
data
->
whole_window
,
(
HCURSOR
)
lp
);
release_win_data
(
data
);
}
else
if
(
hwnd
==
x11drv_thread_data
()
->
clip_hwnd
)
else
if
(
hwnd
==
x11drv_thread_data
()
->
clip_hwnd
)
set_window_cursor
(
x11drv_thread_data
()
->
clip_window
,
(
HCURSOR
)
lp
);
set_window_cursor
(
x11drv_thread_data
()
->
clip_window
,
(
HCURSOR
)
lp
);
return
0
;
return
0
;
...
...
dlls/winex11.drv/x11drv.h
View file @
313157a0
...
@@ -557,7 +557,6 @@ struct x11drv_win_data
...
@@ -557,7 +557,6 @@ struct x11drv_win_data
extern
struct
x11drv_win_data
*
get_win_data
(
HWND
hwnd
)
DECLSPEC_HIDDEN
;
extern
struct
x11drv_win_data
*
get_win_data
(
HWND
hwnd
)
DECLSPEC_HIDDEN
;
extern
void
release_win_data
(
struct
x11drv_win_data
*
data
)
DECLSPEC_HIDDEN
;
extern
void
release_win_data
(
struct
x11drv_win_data
*
data
)
DECLSPEC_HIDDEN
;
extern
struct
x11drv_win_data
*
X11DRV_get_win_data
(
HWND
hwnd
)
DECLSPEC_HIDDEN
;
extern
Window
X11DRV_get_whole_window
(
HWND
hwnd
)
DECLSPEC_HIDDEN
;
extern
Window
X11DRV_get_whole_window
(
HWND
hwnd
)
DECLSPEC_HIDDEN
;
extern
XIC
X11DRV_get_ic
(
HWND
hwnd
)
DECLSPEC_HIDDEN
;
extern
XIC
X11DRV_get_ic
(
HWND
hwnd
)
DECLSPEC_HIDDEN
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment