Community
Participate
Working Groups
Porting the "org.eclipse.ui.activities" and "org.eclipse.ui.activitySupport" to RAP. I (Elias) I'm already working on this and use this issue to track progress.
Created attachment 90004 [details] Support for activities in RAP I've attached a patch, so we can discuss the current status. [Scope] With regard to org.eclipse.ui.activities, support is being added for the following contributions: - Views and Editors - Perspectives - Menus and toolbars Also included is the org.eclipse.ui.activitySupport extension point. Activity support for these contributions is excluded, because they are currently not available in RAP: - Preference and Property pages - Creation Wizards (New-, Import-, Export-Wizards) Also excluded is activity support for Help Items (handled by the org.eclipse.help.base.activitySupport extension point) and the Capabilities Preference page. [Status] - Ported IWorkbenchActivitysupport; related classes; .exsd files from Eclipse 3.3. - Ported activity tests from org.eclipse.ui.tests; 41/42 green; 1 intentional failure (related to persistence). - Added "@since 1.1" to API parts - Manually tested different use cases with example app [Discuss] 1. Ok with scope? 2. In Eclipse RCP activity settings are persisted using Preferences (ActivityPersistenceHelper class). This patch does not support any persistence (i.e. activities are not persisted beyond the scope of the session). Is that ok? 3. There is a "Prompt when enabling capabilities" workbench preference. Is this something that the patch should support? Currently I do not support this. I assume this setting is set to "false", meaning that the user will not asked to confirm enablement of interactive activities (see ITriggerPoint.INTERACTIVE). Note that one override this, by changing the TriggerPointAdvisor via the org.eclipse.ui.activitySupport extension point using a triggerPointAdvisorProductBinding (you also need to specify a product and an application but it works). 4. Testing: I've hacked the activity UI tests to make them work with RAP. I've attached this as a separated patch. If this is something you would like to see added to the RAP tests, we should discuss how to properly launch the tests and into which plug-in they should go... --- Note to self: Search for references of WorkbenchActivityHelper to see where activities are used inside the workbench code
Created attachment 90005 [details] Sample app utilizing the activities / activitySupport extension points This sample app can be used to experiment with the implementation. It is not intented to be committed.
Created attachment 90006 [details] Test cases for activities from org.eclipse.ui.tests This project contains a port of activities related tests from org.eclipse.ui.tests. It is provided for experimenting with the current implementation. It is not intented to be committed.
Hi Elias, I'll not have the time to look at the patches in the next days, just some hints I remember from the workbench migration: * do a search on the workbench code (+maybe views plugin) for "//*WorkbenchActivityHelper" to get at least to most cases of activity support * consider porting the CapabilityFilter which is used across the platform as filter for JFace viewers * there are some TODO markers in the workbench code like "[bm] activities" After reading your last posts again it seems you already caught most of the cases. I'll still leave the comment fyi.
(In reply to comment #1) Discussed open issues with Frank. Here's what we agreed on: 1. Scope is ok. 2. Support for persisting activity settings is not necessary right now. 3a. Will assume that the "Prompt when enabling capabilities" preference is always set to TRUE (not false). The idea is that the reason for having a trigger point *is* to have the user acknowledge the enablement, so assuming the the "prompt preference" is *always* false contradicts the trigger point concept. If one wants to supress the prompt he can still do so by contributing a custom TriggerPointAdvisor. 3b. Will change the <triggerPointAdvisorProductBinding> to bind to the ID of the currently active Branding (since that is the equivalent of a "Product" in RAP). 4. Ok with keeping the test-code attached to this bug. No immediate plan for inclusion. I'm now working on an updated patch.
Created attachment 90266 [details] Support for activities in RAP
Created attachment 90267 [details] Sample app utilizing the activities / activitySupport extension points
Created attachment 90268 [details] Test cases for activities from org.eclipse.ui.tests Adjusted to Rap 1.1 M3.
Attachment 90266 [details] contains the latest code. https://bugs.eclipse.org/bugs/attachment.cgi?id=90266 From my point of view it's ready... Regards, Elias.
Changes are in CVS-Head.