Skip to main content



      Home
Home » Eclipse Projects » GEF » Redo/Undo in GEF and Eclipse
Redo/Undo in GEF and Eclipse [message #13964] Thu, 18 July 2002 08:08 Go to next message
Eclipse UserFriend
Hi
In my editorpart, the context menu shows und/redo to the previously
executed commands, in a similar way that is in the logic example. my
problem is that even if there is something to undo/redo, and the context
menu entries are enabled, in the eclipse menu Edit->Undo, or Edit-Redo,
are not enabled. moreover, the shrtcuts ctrl-Z and ctrl-y does not work.
what can i do to connect between my commands and this menu?
Re: Redo/Undo in GEF and Eclipse [message #13983 is a reply to message #13964] Thu, 18 July 2002 11:25 Go to previous message
Eclipse UserFriend
Are you using GEF's ActionBarContributor? In
ActionBarContributor.setActiveEditor(IEditorPart), the global actions (undo,
redo, and delete) are registered with the ActionBars.

for (int i=0; i<globalActions.size(); i++) {

id = (String)globalActions.get(i); // i.e.
IWorkbenchActionContants.UNDO

bars.setGlobalActionHandler(id,registry.getAction(id)); //
register this action as the global handler

}

I'm not sure why the toolbar items work without this and the menu items don't.

Eric


"Yoav Rubin" <yoav@il.ibm.com> wrote in message
news:ah6b34$kc9$1@rogue.oti.com...
> Hi
> In my editorpart, the context menu shows und/redo to the previously
> executed commands, in a similar way that is in the logic example. my
> problem is that even if there is something to undo/redo, and the context
> menu entries are enabled, in the eclipse menu Edit->Undo, or Edit-Redo,
> are not enabled. moreover, the shrtcuts ctrl-Z and ctrl-y does not work.
> what can i do to connect between my commands and this menu?
>
Previous Topic:dynamic actions
Next Topic:UML Plugin
Goto Forum:
  


Current Time: Sat Jul 05 07:03:32 EDT 2025

Powered by FUDForum. Page generated in 0.04257 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top