I have a main component, with a main menu and some keyboard shortcuts associated to it (like ctr-c for copy, ctrl-z for undo, and so on …)
I noticed that they work only until I click on another component, then, by default the other component takes the focus, because in internalMouseDown, there’s this code
[code] if (! flags.dontFocusOnMouseClickFlag)
grabFocusInternal (focusChangedByMouseClick, true);
if (checker.shouldBailOut()) return; }
I would like my main menu shortcuts to work, whatever component has the keyboard focus. Is there a way to do that ?
The other option would be to set the ‘dontFocusOnMouseClickFlag’ to true for every other component but that’s tedious and I guess that would prevent text entry on some text fields …