Code: Select all
EnableExplicit
Define.i evWW, evM
#EV_KS_0 = 100
#EV_KS_Pad0 = 101
#EV_KS_SHIFT_0 = 102
#EV_KS_SHIFT_Pad0 = 103
If OpenWindow(0, 0, 0, 220, 220, "BUG v571 - Shift+Padn menu event?", #PB_Window_SystemMenu | #PB_Window_ScreenCentered)
StringGadget(1, 10, 20, 150, 32, "ABC")
AddKeyboardShortcut(0, #PB_Shortcut_0, #EV_KS_0)
AddKeyboardShortcut(0, #PB_Shortcut_Pad0, #EV_KS_Pad0)
AddKeyboardShortcut(0, #PB_Shortcut_Shift | #PB_Shortcut_0, #EV_KS_SHIFT_0)
AddKeyboardShortcut(0, #PB_Shortcut_Shift | #PB_Shortcut_Pad0, #EV_KS_SHIFT_Pad0)
Repeat
evWW = WaitWindowEvent()
Select evWW
Case #PB_Event_Menu
evM = EventMenu()
;ClearDebugOutput()
If evM = #EV_KS_0
Debug "Just 0"
ElseIf evM = #EV_KS_Pad0
Debug "Pad0"
ElseIf evM = #EV_KS_SHIFT_0
Debug "Shift+0"
ElseIf evM = #EV_KS_SHIFT_Pad0
Debug "Shift+Pad0"
EndIf
Case #PB_Event_CloseWindow
Break
EndSelect
ForEver
EndIf