Thanks in advance.
Thomas]]>Thomas Singer2012-01-13T12:53:52-00:00Re: Del-accelerator conflicts with del-&quot;action&quot; in text fieldhttps://www.eclipse.org/forums/index.php/mv/msg/275962/778615/#msg_778615
I think the existing behavior is as expected.
To prevent the menuitem from being selected, you could disable it when the focus is in the input field.
But, in this case, since the delete action is valid in the input field, you could probably implement a delete action for the input field and call it on menu item's selection.

I would not expect it. I would expect that the focused component could handle the key first, then all parent controls and if it was not processed, then the accelerator would be used. At least that's how Swing did it.

Lakshmi Shanmugam wrote on Fri, 13 January 2012 09:14

To prevent the menuitem from being selected, you could disable it when the focus is in the input field.

That would be VERY hard in our application, because the menu item (aka its belonging action) does not (and should not) know anything about input fields or a focused control.

Lakshmi Shanmugam wrote on Fri, 13 January 2012 09:14

But, in this case, since the delete action is valid in the input field, you could probably implement a delete action for the input field and call it on menu item's selection.

The delete key was just a sample. The user of our application is free to change the accelerators to their needs. Hence similar conflicts may happen for any key which is used by input fields.