|
|
|
|
Re: Call to a command defined in another plugin [message #894882 is a reply to message #894619] |
Tue, 10 July 2012 22:05 ![Go to previous message Go to previous message](theme/Solstice/images/up.png) ![Go to next message Go to next message](theme/Solstice/images/down.png) |
Vince Cadmus![Friend of Eclipse Friend](/donate/web-api/friends_decorator.php?email=vauffray%40hotmail.com) Messages: 16 Registered: July 2012 |
Junior Member |
|
|
Well, in fact, trying to do the same in an Eclipse 3.x way, I don't know if I'm doing it well :
In an Eclipse 3.x RCP application, I just tried to add in the plugin.xml a menu contribution with a menu/command targetting the org.eclipse.ui.window.preferences command (just filling the commandId attribute of the menuContribution/menu/command element). And it works !
The trouble is that in an Application.e4xmi file, I couldn't do the same : when trying to fill the Command for my HandledMenuItem (using the "find" button in the model editor), I can only choose commands described in this same file, nothing coming from other plugins ! By the way, I think the plugin.xml editor uses the listed dependencies to look for the commands, but as the Application.e4mi file does not list any dependency, I'm not sure it could be possible to achieve the same.
So the question becomes : in an Application.e4xmi file, how can I use in a menu a command defined in another plugin ? As it is possible using the extensions of the plugin.xml file for a 3.x RCP application, I guess it should also be possible for an Eclipse 4 application, but I can't find how ![Sad](images/smiley_icons/icon_sad.gif)
Thanks !
|
|
|
|
Re: Call to a command defined in another plugin [message #896000 is a reply to message #895123] |
Mon, 16 July 2012 19:53 ![Go to previous message Go to previous message](theme/Solstice/images/up.png) ![Go to next message Go to next message](theme/Solstice/images/down.png) |
Vince Cadmus![Friend of Eclipse Friend](/donate/web-api/friends_decorator.php?email=vauffray%40hotmail.com) Messages: 16 Registered: July 2012 |
Junior Member |
|
|
I was trying to use in my model (the Applicatiobn.e4xmi file) a command defined in a standard 3.X module (to open the prefs dialog), and I think I have more or less understood my problem : to use a 3.x plugin with UI contributions, you have to start the Eclipse 4 application in compatibiliy mode (using the IDEApplication for instance). If you develop and start an Eclipse 4 application without using this compatibility mode, you won't be able to use UI contributions (eg commands or menus) from 3.X plugins. Right ?
But so I have another question : isn'it possible to mix 3.x and 4 plugins (with UI contributions) in the same application ? As most the "standard" plugins (let's say, the ones coming with "Eclipse for J2EE") are still 3.x modules, can't I use them in a Eclipse 4 application without the compatibiliy layer ? And if I have to use the compatibility layer, so does it mean I won't be able to run in this Eclipse 4 application some 4.x plugins with UI contributions (or may be the compatibility layer is able to use both 3.x and 4.x plugins, reading both UI extension points from plugin.xml and contributions from fragments ?). If for instance I need to develop some plugins (with UI contributions) that I would like to make available in a standard Eclipse workbench, but also use in a standalone application, can't I develop them using Eclipse 4 UI features ?
I'm afraid I'm a bit lost with this (and not sure this is the right forum to ask about this, if not just tell me )
[Updated on: Mon, 16 July 2012 19:54] Report message to a moderator
|
|
|
|
Powered by
FUDForum. Page generated in 0.04446 seconds