Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Eclipse Platform » CNF : tool bar actions
CNF : tool bar actions [message #521700] Thu, 18 March 2010 14:08 Go to next message
Nathalie Lepine is currently offline Nathalie LepineFriend
Messages: 28
Registered: July 2009
Junior Member
Hi,

I am using CNF to define my own view : this view is synchronized with
another view which represents a diagram editor. When the focus on the
diagram editor, i have access to many buttons in the tool bar (like
save, undo, redo...). When i focus on the diagram editor and after on
another view, i always have access to the the same actions in the tool
bar because these are the diagram editor actions. But when i focus to my
CNF view, i do not have access to these tool bar actions as if the CNF
view reinitialize the actions.
Is it possible that the CNF view do not do that and keep the actions of
the diagram editor ?

Thanks,

Nathalie Lepine
Re: CNF : tool bar actions [message #521817 is a reply to message #521700] Thu, 18 March 2010 19:24 Go to previous message
Francis Upton IV is currently offline Francis Upton IVFriend
Messages: 472
Registered: July 2009
Location: Oakland, CA
Senior Member
Yes, you can do this using the action providers extension points and implementing CommonActionProviders which can update their state based on the selection in your CN view.

There are several action provides implemented for the Project Explorer in the org.eclipse.ui.navigator.resources.actions package and these case be used as a place to start.

Another way you can do this is to use the Commands infrastructure to enable the handlers for some of these actions based on an enablement expression that considers the view (your viewpart id) and the current selection. But I'm a little fuzzy on how to do that. I suggest you read about commands and if it's not clear post something that will get Paul Webster's attention and he can help you further.


Previous Topic:What APIs should I investigate for contributing children to resources in the Project Explorer?
Next Topic:Not able to download older plugin dependencies
Goto Forum:
  


Current Time: Thu Apr 25 08:08:37 GMT 2024

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

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

Back to the top