Community
Participate
Working Groups
In order to synchronize enablement behavior of global clipboard actions managed by TextActionHandler with Text control's native context menu, the following rules should be observed: 1. Cut, Paste and Delete should only be enabled for editable Text fields 2. In addition, Paste should only be enabled if there is textual content on the clipboard 3. Select All should only be enabled when there is at least one character in the Text control Furthermore, TextActionHandler does not properly update enablement in its addText(Text) method. For one, it assumes that the Text control being added is currently active, OR that this method will be called before set<Action>(IAction) methods are (which properly update enablement). This may not be the case, particularly in scenarios where the global actions are shared (e.g., editor's action bar contributor) and controls are added only after the actions have been set. This is in follow-up to bugs.eclipse.org/bugs/show_bug.cgi?id=124673. Apparently, I didn't catch all of the problems with TextActionHandler. A proposed patch is attached.
Created attachment 33686 [details] Proposed patch to fix the outlined problems
Moving Dougs bugs
Released to HEAD >20090125 PW
verified using the tests in bug 262615 on I20090127-0100