views:

205

answers:

1

I'm developing an Eclipse RCP based application, that uses the resource model of eclipse (workspace, projects, resources, etc.). For basic usage of the resource concept, there is no need to depend on the IDE plug-in. But many dialogs, wizards or views I want to use are inside this plug-in. I read about not to have any dependencies on IDE plug-ins in an RCP app.

For example, I want to implement a new project wizard and use the common look and functionality of the existing ones by overriding org.eclipse.ui.dialogs.WizardNewProjectCreationPage and using org.eclipse.ui.wizards.newresource.BasicNewProjectResourceWizard - both inside the IDE plug-in.

Are there any caveats using org.eclipse.ui.ide plug-in in an RCP app?

If so, what is your best practice to not reinvent the wheel?

+1  A: 

As you can see with this thread (or that one), since eclipse3.3, most the the components of org.eclipse.ui.ide have been isolated in their own plugin.

So it can be a good practice to include what you need from that package, the only problem being to include to much contributions.
This thread gives a hint as how to remove some of them.
You can, for example, disable export and import wizards.
Both of those examples are based on Activity filtering

An activity is a logical grouping of function that is centered around a certain kind of task.
For example, developing Java software is an activity commonly performed by users of the platform, and the JDT defines many UI contributions (views, editors, perspectives, preferences, etc.) that are only useful when performing this activity.

  • Activities can be used to implement progressive disclosure of UI elements; when used for this purpose, they are called capabilities in the UI.
  • The second use for activities, added for Eclipse 3.4, is to filter available UI elements based on other criteria such as the current user's access permissions as defined by the application.

This article "Eclipse Activities – Hide / Display certain UI elements" by Lars Vogel in his "papercut series" gives a good illustration of hiding / displaying certain UI elements.

VonC