Bug 193981 - Activities are not Dynamic-Aware
Summary: Activities are not Dynamic-Aware
Status: RESOLVED WORKSFORME
Alias: None
Product: Platform
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 3.2   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Kim Horne CLA
QA Contact:
URL:
Whiteboard:
Keywords: needinfo
: 193989 193990 193994 (view as bug list)
Depends on:
Blocks:
 
Reported: 2007-06-22 10:07 EDT by Zouaoui Anis CLA
Modified: 2009-07-15 13:42 EDT (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Zouaoui Anis CLA 2007-06-22 10:07:58 EDT
Hi,
I'm trying to apply at runtime filters on some views in all my perspectives, even perspectives are already opened or not. 

For this, I create and register at runtime an Activity and it's activityPatternBinding that refer the views I want to hide. 

The new Activity was correctly created and registered in the ExtensionRegistry. But, the IWorkbenchActivitySupport didn't take it in consideration.

The WorkbenchActivitySupport implements IExtensionChangeHandler but was not notified of changes for activity extension point, It sound to be a bug.

Thanks in advance,
Anis
Comment 1 Denis Roy CLA 2007-06-22 10:10:32 EDT
Have you asked about this on the eclipse.platform newsgroup before opening a bug?
Comment 2 Denis Roy CLA 2007-06-22 10:40:43 EDT
*** Bug 193989 has been marked as a duplicate of this bug. ***
Comment 3 Denis Roy CLA 2007-06-22 10:40:49 EDT
*** Bug 193990 has been marked as a duplicate of this bug. ***
Comment 4 Denis Roy CLA 2007-06-22 11:07:53 EDT
*** Bug 193994 has been marked as a duplicate of this bug. ***
Comment 5 Gunnar Wagenknecht CLA 2007-06-22 13:24:59 EDT
moving to Platform UI
Comment 6 Kim Horne CLA 2007-06-22 14:00:38 EDT
The activity support only reacts to changes for the activitySupport extension point, not the activity extension point.

I'm wondering if it's simply not a matter of it not doing what you expect it to.  When activities come into the system existing realized contributions (views, for instance) wont disappear - activities aren't supposed to be aggressive like that.  The pattern bindings should take affect on any new view, editor or perspective  you try and open but it should affect those that are already open.  Is this what you were expecting?
Comment 7 Zouaoui Anis CLA 2007-06-22 15:30:48 EDT
Here is my scenario;
  My application is connected to an LDAP server. It has a cache that refreshes 
access rights on views depending on changes on server.

I have two main cases: 

1- Non authorized views are already opened on the activePage : I'm hiding them
using activePage.hideView(IViewReference view). 

2- Non authorized views belong to non opened perspectives (not alreay created): I create/register an
activity extension point and its pattern binding with the correct regexp. Since
my activity is disabled by default, I'm expecting that my activity enter in the
game and filter the restricted views (before there creation) when opening
perspectives. But the newly created activity has no effect, it was not
registered in the activity.

It would be appreciated if activities API take in consideration non
non-persisted activities.

Regards
Comment 8 Kim Horne CLA 2007-06-22 15:34:17 EDT
As near as I can tell it's working.  Could you attach a sample plug-in that clearly demonstrates the defect please?
Comment 9 Susan McCourt CLA 2009-07-15 13:42:20 EDT
closing as WORKSFORME based on comment 8.  Please reopen and attach a sample if this is not true.