can't enable GlobalActionHandler [message #143047] |
Mon, 13 October 2003 14:36 |
Federico Messages: 12 Registered: July 2009 |
Junior Member |
|
|
Hi all!
I'm trying to override the system menu action "Project" -> "Rebuild
Project", because I would like to provide a special build functionality.
I'm using:
//rebuild project
myRebuildAction = new MyRebuildAction();
getViewSite().getActionBars().setGlobalActionHandler(org.ecl ipse.ui.IWorkbenchActionConstants.REBUILD_PROJECT,
myRebuildAction);
It works fine, but I don't manage to get the action enabled if an editor
is enabled (if I get the object related to my editor and start the action
it works fine). I registered a PartListener and in partActivated() method
I wanted to use myRebuildAction.setEnabled(true).
Where is the error to locate? Was this action not meant to be overridden
in this way? Is there a different way to solve the problem?
Thank you in advance for an answer!
Fed
|
|
|
Powered by
FUDForum. Page generated in 0.02188 seconds