|From a command handler how can I know if it is invoked? [message #660927]
||Tue, 22 March 2011 07:53
| David Pérez
Registered: July 2009
I need to know from a command handler if it is invoked from the keyboard or other means (menu item, mouse, ....).|
Because if it is invoked from the keyboard, which control has the focus matters.
I have a view with a table and a text field for searching inside the table.
Suppose that Ctrl+C is the shorcut for the command that copies the contents of the current row in the table to the clipboard.
If I select this command from a toolbar, focus doesn't matter.
But if I press Ctrl+C, I would like the behaviour to be adjusted:
- If the text field has the focus
- Or some other control like the table has the focus
I've checked HandlerUtil but haven't seen anything useful.
Powered by FUDForum
. Page generated in 0.01718 seconds