Directly generate EVT_CONTEXT_MENU when Applications (Menu) key is pressed
WM_CONTEXTMENU message is generated directly by the system when the user presses and releases the VK_APPS key so there is no need to do this by emulating right mouse button click. Closes #17969.
This commit is contained in:
parent
f34a6253c7
commit
2c69d27c0d
@ -3055,12 +3055,6 @@ wxWindowMSW::MSWHandleMessage(WXLRESULT *result,
|
||||
case VK_OEM_PERIOD:
|
||||
break;
|
||||
|
||||
// special case of VK_APPS: treat it the same as right mouse
|
||||
// click because both usually pop up a context menu
|
||||
case VK_APPS:
|
||||
processed = HandleMouseEvent(WM_RBUTTONDOWN, -1, -1, 0);
|
||||
break;
|
||||
|
||||
default:
|
||||
if ( (wParam >= '0' && wParam <= '9') ||
|
||||
(wParam >= 'A' && wParam <= 'Z') )
|
||||
@ -3096,15 +3090,7 @@ wxWindowMSW::MSWHandleMessage(WXLRESULT *result,
|
||||
|
||||
case WM_SYSKEYUP:
|
||||
case WM_KEYUP:
|
||||
// special case of VK_APPS: treat it the same as right mouse button
|
||||
if ( wParam == VK_APPS )
|
||||
{
|
||||
processed = HandleMouseEvent(WM_RBUTTONUP, -1, -1, 0);
|
||||
}
|
||||
else
|
||||
{
|
||||
processed = HandleKeyUp((WORD) wParam, lParam);
|
||||
}
|
||||
processed = HandleKeyUp((WORD) wParam, lParam);
|
||||
break;
|
||||
|
||||
case WM_SYSCHAR:
|
||||
|
Loading…
Reference in New Issue
Block a user