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
731e497a
Commit
731e497a
authored
Sep 18, 2012
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
winex11: Add window data locking to the drag and drop functions.
parent
1cfed892
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
8 deletions
+10
-8
event.c
dlls/winex11.drv/event.c
+10
-8
No files found.
dlls/winex11.drv/event.c
View file @
731e497a
...
...
@@ -1286,22 +1286,23 @@ static void EVENT_DropFromOffiX( HWND hWnd, XClientMessageEvent *event )
unsigned
long
aux_long
;
unsigned
char
*
p_data
=
NULL
;
Atom
atom_aux
;
int
x
,
y
,
dummy
;
int
x
,
y
,
cx
,
cy
,
dummy
;
BOOL
bAccept
;
Window
win
,
w_aux_root
,
w_aux_child
;
win
=
X11DRV_get_whole_window
(
hWnd
);
if
(
!
(
data
=
get_win_data
(
hWnd
)))
return
;
cx
=
data
->
whole_rect
.
right
-
data
->
whole_rect
.
left
;
cy
=
data
->
whole_rect
.
bottom
-
data
->
whole_rect
.
top
;
win
=
data
->
whole_window
;
release_win_data
(
data
);
XQueryPointer
(
event
->
display
,
win
,
&
w_aux_root
,
&
w_aux_child
,
&
x
,
&
y
,
&
dummy
,
&
dummy
,
(
unsigned
int
*
)
&
aux_long
);
x
+=
virtual_screen_rect
.
left
;
y
+=
virtual_screen_rect
.
top
;
if
(
!
(
data
=
X11DRV_get_win_data
(
hWnd
)))
return
;
/* find out drop point and drop window */
if
(
x
<
0
||
y
<
0
||
x
>
(
data
->
whole_rect
.
right
-
data
->
whole_rect
.
left
)
||
y
>
(
data
->
whole_rect
.
bottom
-
data
->
whole_rect
.
top
)
)
if
(
x
<
0
||
y
<
0
||
x
>
cx
||
y
>
cy
)
{
bAccept
=
GetWindowLongW
(
hWnd
,
GWL_EXSTYLE
)
&
WS_EX_ACCEPTFILES
;
x
=
0
;
...
...
@@ -1439,7 +1440,7 @@ static void EVENT_DropURLs( HWND hWnd, XClientMessageEvent *event )
hDrop
=
GlobalAlloc
(
GMEM_SHARE
,
drop_len
);
lpDrop
=
GlobalLock
(
hDrop
);
if
(
lpDrop
&&
(
win_data
=
X11DRV_
get_win_data
(
hWnd
)))
if
(
lpDrop
&&
(
win_data
=
get_win_data
(
hWnd
)))
{
lpDrop
->
pFiles
=
sizeof
(
DROPFILES
);
lpDrop
->
pt
.
x
=
x
;
...
...
@@ -1451,6 +1452,7 @@ static void EVENT_DropURLs( HWND hWnd, XClientMessageEvent *event )
y
>
(
win_data
->
client_rect
.
bottom
-
win_data
->
whole_rect
.
top
)
);
lpDrop
->
fWide
=
FALSE
;
p_drop
=
(
char
*
)(
lpDrop
+
1
);
release_win_data
(
win_data
);
}
/* create message content */
...
...
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