Allright, I’ve researched this for the last hour, and zero luck. I have found how to hotkey/shortcut to a menu item, but zero answers on how to do this simply within an editor script.
For example, my script shows a gizmo in the scene view. I would like the user to press “t” to toggle on/off that gizmo, at any time.
Now, I can get “t” to work if I check the event from “OnGUI”, but of course that only works while the editorwindow with my script is selected. Not very hand, since the user would have to keep re-selecting the editor window before pressing the shortcut key.
There absolutely must be a way to do this…but I am at a complete loss. Any help here? Thanks much!!