Otherwise you have to wait for a mouse movement to see if a modifier has been released.
Canvas - #PB_EventType_ModifierUp
Canvas - #PB_EventType_ModifierUp
#PB_EventType_ModifierUp could come in handy. That way it could be used like "Case #PB_EventType_ModifierUp". 
Otherwise you have to wait for a mouse movement to see if a modifier has been released.
Otherwise you have to wait for a mouse movement to see if a modifier has been released.
www.posemotion.com
PureBasic Tools for OS X: PureMonitor, plist Tool, Data Maker & App Chef
Even the vine knows it surroundings but the man with eyes does not.
PureBasic Tools for OS X: PureMonitor, plist Tool, Data Maker & App Chef
Even the vine knows it surroundings but the man with eyes does not.
Re: Canvas - #PB_EventType_ModifierUp
you can use #PB_EventType_KeyUp
Code: Select all
Enumeration
#Window
#Gadget
EndEnumeration
OpenWindow(#Window, 0, 0, 800, 600, "WindowTitle", #PB_Window_MinimizeGadget|#PB_Window_ScreenCentered)
CanvasGadget(#Gadget, 0, 0, WindowWidth(#Window), WindowHeight(#Window), #PB_Canvas_Keyboard)
Repeat
Select WaitWindowEvent()
Case #PB_Event_CloseWindow
End
Case #PB_Event_Gadget
Select EventGadget()
Case #Gadget
Select EventType()
Case #PB_EventType_KeyDown
Debug GetGadgetAttribute(#Gadget, #PB_Canvas_Modifiers)
Case #PB_EventType_KeyUp
Debug GetGadgetAttribute(#Gadget, #PB_Canvas_Modifiers)
EndSelect
EndSelect
EndSelect
ForEverPB 6.01 ― Win 10, 21H2 ― Ryzen 9 3900X, 32 GB ― NVIDIA GeForce RTX 3080 ― Vivaldi 6.0 ― www.unionbytes.de
Lizard - Script language for symbolic calculations and more ― Typeface - Sprite-based font include/module
Lizard - Script language for symbolic calculations and more ― Typeface - Sprite-based font include/module
Re: Canvas - #PB_EventType_ModifierUp
Thanks but that doesn't work on OS X. Must be a bug. Which is weird because I thought I had tested the #PB_EventType_KeyUp and it worked with a few keys I tested, just not Shift. So I assumed the "Modifiers" didn't work with #PB_EventType_KeyUp.
I was using, "If GetGadgetAttribute(1, #PB_Canvas_Modifiers) = #PB_Canvas_Shift" without the #PB_Canvas_Keyboard flag which works and is nice because then it doesn't effect my keyboard shortcuts.
Thanks again for trying to help though.
I was using, "If GetGadgetAttribute(1, #PB_Canvas_Modifiers) = #PB_Canvas_Shift" without the #PB_Canvas_Keyboard flag which works and is nice because then it doesn't effect my keyboard shortcuts.
Thanks again for trying to help though.
www.posemotion.com
PureBasic Tools for OS X: PureMonitor, plist Tool, Data Maker & App Chef
Even the vine knows it surroundings but the man with eyes does not.
PureBasic Tools for OS X: PureMonitor, plist Tool, Data Maker & App Chef
Even the vine knows it surroundings but the man with eyes does not.
Re: Canvas - #PB_EventType_ModifierUp
I was actually able to rework my app to function differently and no longer need to check if the modifier was released or not. 
www.posemotion.com
PureBasic Tools for OS X: PureMonitor, plist Tool, Data Maker & App Chef
Even the vine knows it surroundings but the man with eyes does not.
PureBasic Tools for OS X: PureMonitor, plist Tool, Data Maker & App Chef
Even the vine knows it surroundings but the man with eyes does not.
