Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Rich Client Platform (RCP) » How to organize actions in plugin.xml
How to organize actions in plugin.xml [message #453358] Thu, 27 July 2006 11:28 Go to next message
Javier Rodriguez is currently offline Javier RodriguezFriend
Messages: 41
Registered: July 2009
Member
Hi,

I would like to have some opinions on the best practice to organize
actions in the plugin.xml file. In my case, I have the same actions
declared for different extensions point (so the declaration of actions are
duplicated in the plugin.xml).

What is your experience on this?

Regards,
Javier
Re: How to organize actions in plugin.xml [message #453359 is a reply to message #453358] Thu, 27 July 2006 12:14 Go to previous messageGo to next message
David is currently offline DavidFriend
Messages: 47
Registered: July 2009
Member
In one of my views, I have actions in a popup menu and in the view
toolbar. If defined in plugin.xml, the framework creates 2 intances of
the action and this is not easy to handle.

Finally, in this special case, I add the actions to popup menu and
toolbar programmatically. This works great.

I don't know the "clear" method to do that but this solution is better
for me (I need to enable / disable the actions depending of a special
state or user selection and both actions (popup menu and toolbar) must
have the same behavior. If the actions are defined in plugin.xml, this
is hardest to handle).

Xavier wrote:
> Hi,
>
> I would like to have some opinions on the best practice to organize
> actions in the plugin.xml file. In my case, I have the same actions
> declared for different extensions point (so the declaration of actions
> are duplicated in the plugin.xml).
>
> What is your experience on this?
>
> Regards,
> Javier
>
Re: How to organize actions in plugin.xml [message #453360 is a reply to message #453359] Thu, 27 July 2006 12:51 Go to previous messageGo to next message
Javier Rodriguez is currently offline Javier RodriguezFriend
Messages: 41
Registered: July 2009
Member
Thanks for your inputs,

So if I understand your point of vue, You only declare actions in the
plugin.xml for actions that must extends menus on others plugins. And
actions for the same plugin are declarer programatically.

Thanks,
Xavier
Re: How to organize actions in plugin.xml [message #453382 is a reply to message #453360] Thu, 27 July 2006 21:46 Go to previous message
David Goetschmann is currently offline David GoetschmannFriend
Messages: 10
Registered: July 2009
Junior Member
mmh that is not really what I would say.
In my case, I have more than one instance of an action which is held by
a view. In this case, I think it is better to share the same instance of
the action by declare it programatically.

But I hope other people can give their input here because, like you, I
need other point of view!

David


Xavier a écrit :
> Thanks for your inputs,
>
> So if I understand your point of vue, You only declare actions in the
> plugin.xml for actions that must extends menus on others plugins. And
> actions for the same plugin are declarer programatically.
>
> Thanks,
> Xavier
>
Previous Topic:perspective not displayed
Next Topic:perspective createInitialLayout never called
Goto Forum:
  


Current Time: Wed Oct 09 12:38:46 GMT 2024

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

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

Back to the top