[Bug 50067] New: Duplicate keyboard message if call PeekMessage from WH_KEYBOARD hook
WineHQ Bugzilla
wine-bugs at winehq.org
Tue Oct 27 12:59:17 CDT 2020
https://bugs.winehq.org/show_bug.cgi?id=50067
Bug ID: 50067
Summary: Duplicate keyboard message if call PeekMessage from
WH_KEYBOARD hook
Product: Wine
Version: 5.20
Hardware: x86-64
OS: Linux
Status: UNCONFIRMED
Severity: normal
Priority: P2
Component: user32
Assignee: wine-bugs at winehq.org
Reporter: psn8402 at gmail.com
Distribution: ---
In the VerseQ keyboard simulator, hotkey events are duplicated. For example F1
opens 2 help windows. Below is an excerpt from the log, where you can see that
while the hook is active, PeekMessage is called, and it receives the same
keypress event. I've added a test for this case. It passes under Windows but
fails in Wine. It looks like on Windows the message is removed from the queue
before the hook is called. Possibly the same problem exists with mouse messages
and rawinput but I haven't tested them.
VerseQ download link https://www.verseq.ru/files/VerseQ.2011.12.31.zip Please
note that it only has a Russian interface.
Log excerpt
342097.147:0024:Call
user32.PeekMessageA(0031fb10,00000000,00000000,00000000,00000001) ret=005d98cc
342097.148:0024:trace:msg:peek_message got type 7 msg 100 (WM_KEYDOWN) hwnd
000300AA wp 73 lp 3e0001
342097.148:0024:Call hook proc 004141A8
(id=WH_KEYBOARD,code=0,wp=00000073,lp=003e0001)
342097.148:0024:Call
user32.PeekMessageA(0031f164,00000000,00000000,00000000,00000001) ret=005d98cc
342097.148:0024:trace:msg:peek_message got type 7 msg 100 (WM_KEYDOWN) hwnd
000300AA wp 73 lp 3e0001
342097.148:0024:Call hook proc 004141A8
(id=WH_KEYBOARD,code=0,wp=00000073,lp=003e0001)
342097.149:0024:Ret hook proc 004141A8
(id=WH_KEYBOARD,code=0,wp=00000073,lp=003e0001) retval=00000000
0024: accept_hardware_message( hw_id=00000095 )
0024: accept_hardware_message() = 0
342097.151:0024:Ret user32.PeekMessageA() retval=00000001 ret=005d98cc
342097.166:0024:Ret hook proc 004141A8
(id=WH_KEYBOARD,code=0,wp=00000073,lp=003e0001) retval=00000000
0024: accept_hardware_message( hw_id=00000095 )
0024: accept_hardware_message() = 0
342097.166:0024:Ret user32.PeekMessageA() retval=00000001 ret=005d98cc
--
Do not reply to this email, post in Bugzilla using the
above URL to reply.
You are receiving this mail because:
You are watching all bug changes.
More information about the wine-bugs
mailing list