Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 73820 - Contextual launch for runtime workbench
Summary: Contextual launch for runtime workbench
Status: RESOLVED FIXED
Alias: None
Product: PDE
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 3.0   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: 3.1 M2   Edit
Assignee: PDE-UI-Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 71131
  Show dependency tree
 
Reported: 2004-09-13 18:12 EDT by Wassim Melhem CLA
Modified: 2004-09-19 20:59 EDT (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Wassim Melhem CLA 2004-09-13 18:12:39 EDT
The contextual launch of a runtime workbench should become sensitive to the 
current workspace selection (much like the behavior with the JUnit Plugin 
launcher).  Right now, the default behavior is to always launch with all the 
workspace and enabled external plugins.  This behavior should be changed as 
follows:
If the current workspace selection is a plugin project whose plugin.xml 
declares a product, then we launch with this plugin and all its pre-reqs only, 
and with this plugin's product id as the eclipse.product setting, etc.
Comment 1 Wassim Melhem CLA 2004-09-18 22:43:12 EDT
This function is almost done.

Ed, given your comment in bug 45439:
"That thing about adding newly imported projects being added automatically 
bites me from time to time even with regular IDE plug-in development. 
Sometimes I want it to add, sometimes I don't, so I can't think of a good way 
to handle it with an option."

I have added a checkbox to the Plugins tab of the launch config.

However, for a launch shortcut generate through the context menu, which is the 
focus here, which one would you arbitrarily pick as more convenient:
to turn the flag on to automatically add workspace plugins to the config or to 
turn it off.
Comment 2 Wassim Melhem CLA 2004-09-18 22:55:31 EDT
bug referenced should have read bug 53439
Comment 3 Ed Burnette CLA 2004-09-19 16:57:43 EDT
Whichever one you pick is going to be wrong sometimes, but I think it would 
make sense that for a selective launch, where you are picking a small subset 
of plug-ins to be active, that the option should default to NOT automatically 
adding to that subset so the same subset will be active. For a launch that is 
going to select every plug-in then it would make sense for the option to 
default to add any new ones that come along so it will still have every plug-
in.

Right now when I do a contextual launch of a plug-in it just gives me a list 
of existing launch configs and asks me to pick one. I assume you're changing 
that to create a new config like the contextual launch for a regular Java app?

The test you're doing to decide whether or not to use all plug-ins is based on 
what? Whether or not there is an application defined in plugin.xml? Somebody 
suggested a new RCP Application Nature, which I believe would make more sense. 
Besides this launching behavior, the nature could be used for a different icon 
and contextual menu changes. Maybe other uses for the nature could be thought 
of in the future, such as a properties page on the project to list what other 
plugins should go into the application besides just direct dependencies. 
Perhaps a builder that would keep config.ini up to date when new dependencies 
were added if update.configurator were not used. Another idea would be 
something with activities that would trigger more functionality when there was 
a project that had RCP Application nature.
Comment 4 Wassim Melhem CLA 2004-09-19 18:14:36 EDT
Thanks Ed.

>the option should default to NOT automatically adding to that subset so the 
>same subset will be active.
Done.

>The test you're doing to decide whether or not to use all plug-ins is based 
>on what? Whether or not there is an application defined in plugin.xml?

Here is the behavior as it will appear in M2:

1. If the selected plugin does not contain an application, then, if no launch 
configs associated with this application exists, we create a new launch 
configuration and set the the "workbench" with the default settings.
Same as today.

2. If the selected plugin defines an application, then, if no launch configs 
associated with this application exists, we create a new launch this 
application with a with the minimal set of plugins needed to launch, ie. the 
third option of the third tab, and we launch.

3. If the selected plugin defines more than one application, then we give you 
a dialog containing the possible applications to launch and we ask you to 
choose which one, and we proceed as in 2.

4. In the case where a single launch configuration is already there and is 
compatible with the application you choose, we relaunch it.

5. In the case where >1 launch configurations are already there and are all 
compatible with the chosen application, then we give you the list of launch 
configs that match your chosen application and let you choose from them.

I don't think there is quite a need yet for an RCP nature, because, even prior 
to RCP, the applications extension point has always existed and we are trying 
to resolve the seeminbly deliberate "bias" toward launching the "workbench" 
when using the context menu, which is an inconvenince.
Comment 5 Wassim Melhem CLA 2004-09-19 20:59:55 EDT
Done as per comment 4.