This appears to be the closest thread to my current problem. I'm using maxgui and want a gui button to behave differently if shift or ctrl is held down. Perturbatio's code above appears to have the same problem, here's a slightly modified one to try:
SuperStrict
Graphics 640,480,0,0
Global Quit:Int = False
While Not Quit
UpdateEvents()
Wend
End
Function UpdateEvents()
WaitEvent()
Select EventID()
Case EVENT_KEYDOWN
Cls
DrawText("Eventdata="+EventData()+", EventMods()="+EventMods(),0,0)
Flip
If EventData() = KEY_Q And EventMods() = MODIFIER_CONTROL Then 'MODIFIER_OPTION
Quit = True
EndIf
End Select
End Function
Pressing ctrl or shift triggers it's own event, but then pressing another key whilst still holding ctrl or shift only shows the new keypress, and EventMods() remains zero. Unless i've badly interpreted the doc's, surely EventMods() should display another value depending on which modifier key is held?
I'm sure somebody can solve this easily... Thanks....