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
4fa411fa
Commit
4fa411fa
authored
Aug 03, 2005
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Don't call WaitForMultipleObjectsEx if we are just polling for pending
X events.
parent
bd127b03
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
5 deletions
+12
-5
event.c
dlls/x11drv/event.c
+12
-5
No files found.
dlls/x11drv/event.c
View file @
4fa411fa
...
@@ -274,33 +274,40 @@ static int process_events( Display *display, DWORD mask )
...
@@ -274,33 +274,40 @@ static int process_events( Display *display, DWORD mask )
DWORD
X11DRV_MsgWaitForMultipleObjectsEx
(
DWORD
count
,
const
HANDLE
*
handles
,
DWORD
X11DRV_MsgWaitForMultipleObjectsEx
(
DWORD
count
,
const
HANDLE
*
handles
,
DWORD
timeout
,
DWORD
mask
,
DWORD
flags
)
DWORD
timeout
,
DWORD
mask
,
DWORD
flags
)
{
{
HANDLE
new_handles
[
MAXIMUM_WAIT_OBJECTS
+
1
];
/* FIXME! */
DWORD
i
,
ret
;
DWORD
i
,
ret
;
struct
x11drv_thread_data
*
data
=
TlsGetValue
(
thread_data_tls_index
);
struct
x11drv_thread_data
*
data
=
TlsGetValue
(
thread_data_tls_index
);
if
(
!
data
||
data
->
process_event_count
)
if
(
!
data
||
data
->
process_event_count
)
{
if
(
!
count
&&
!
timeout
)
return
WAIT_TIMEOUT
;
return
WaitForMultipleObjectsEx
(
count
,
handles
,
flags
&
MWMO_WAITALL
,
return
WaitForMultipleObjectsEx
(
count
,
handles
,
flags
&
MWMO_WAITALL
,
timeout
,
flags
&
MWMO_ALERTABLE
);
timeout
,
flags
&
MWMO_ALERTABLE
);
}
/* check whether only server queue handle was passed in */
/* check whether only server queue handle was passed in */
if
(
count
<
2
)
flags
&=
~
MWMO_WAITALL
;
if
(
count
<
2
)
flags
&=
~
MWMO_WAITALL
;
for
(
i
=
0
;
i
<
count
;
i
++
)
new_handles
[
i
]
=
handles
[
i
];
new_handles
[
count
]
=
data
->
display_fd
;
wine_tsx11_lock
();
wine_tsx11_lock
();
XFlush
(
gdi_display
);
XFlush
(
gdi_display
);
XFlush
(
data
->
display
);
XFlush
(
data
->
display
);
wine_tsx11_unlock
();
wine_tsx11_unlock
();
data
->
process_event_count
++
;
data
->
process_event_count
++
;
if
(
process_events
(
data
->
display
,
mask
))
ret
=
count
;
if
(
process_events
(
data
->
display
,
mask
))
ret
=
count
;
else
else
if
(
count
||
timeout
)
{
{
HANDLE
new_handles
[
MAXIMUM_WAIT_OBJECTS
+
1
];
/* FIXME! */
for
(
i
=
0
;
i
<
count
;
i
++
)
new_handles
[
i
]
=
handles
[
i
];
new_handles
[
count
]
=
data
->
display_fd
;
ret
=
WaitForMultipleObjectsEx
(
count
+
1
,
new_handles
,
flags
&
MWMO_WAITALL
,
ret
=
WaitForMultipleObjectsEx
(
count
+
1
,
new_handles
,
flags
&
MWMO_WAITALL
,
timeout
,
flags
&
MWMO_ALERTABLE
);
timeout
,
flags
&
MWMO_ALERTABLE
);
if
(
ret
==
count
)
process_events
(
data
->
display
,
mask
);
if
(
ret
==
count
)
process_events
(
data
->
display
,
mask
);
}
}
else
ret
=
WAIT_TIMEOUT
;
data
->
process_event_count
--
;
data
->
process_event_count
--
;
return
ret
;
return
ret
;
}
}
...
...
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