Changeset 21955 for trunk/src/user32/oslibmsg.cpp
- Timestamp:
- Jan 31, 2012, 10:25:42 PM (14 years ago)
- File:
-
- 1 edited
-
trunk/src/user32/oslibmsg.cpp (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/user32/oslibmsg.cpp
r21916 r21955 548 548 //TODO: QS_HOTKEY 549 549 //****************************************************************************** 550 ULONG OSLibWinQueryQueueStatus( )550 ULONG OSLibWinQueryQueueStatus(ULONG flags) 551 551 { 552 552 ULONG statusOS2, statusWin32 = 0; 553 553 554 554 statusOS2 = WinQueryQueueStatus(HWND_DESKTOP); 555 dprintf(("*** 3 %x", statusOS2)); 556 557 if (flags & QS_KEY) 558 { 559 // WinQueryQueueStatus() has a bug which causes it to always return 560 // the QS_KEY bit set when the associated window is active, regardless 561 // of whether thiere are WM_CHAR messages in the queue or not. We try to 562 // fix this by looking up the queue ourselves if the caller actually 563 // wants this state to be checked 564 QMSG qmsg; 565 BOOL haveKey = WinPeekMsg (0, &qmsg, 0, WM_CHAR, WM_CHAR, PM_NOREMOVE); 566 if (haveKey) 567 { 568 // set the proper "summary" status 569 statusOS2 |= (QS_KEY << 16); 570 } 571 else 572 { 573 statusOS2 &= ~(QS_KEY << 16); 574 // according to PMREF, the "added" field is a subset of the 575 // "summary" field, so it makes no sense to have it set when it is 576 // reset in "summary" 577 statusOS2 &= ~(QS_KEY); 578 } 579 } 555 580 556 581 // convert the flags since last call (low word)
Note:
See TracChangeset
for help on using the changeset viewer.
