|Re: How can I disable capabilities/activities ? [message #280736 is a reply to message #280722]
||Tue, 08 February 2005 19:36
Originally posted by: kim_horne.ca.ibm.com|
You should look at org.eclipse.ui.activities.IWorkbenchActivitySupport.
This interface contains setEnabledActivityIds(Set) which can be used
to alter the activity enablement state. An instancce of
IWorkbenchActivitySupport can be obtained from
Typical usage is as follows:
Set enabledActivities = new
// alter the set by adding or removing activity ids
Chris Laffra wrote:
> Not knowing enough about activities, I did Ctrl+Shift+T on IActivity.
> Then I pressed F4 to get the concrete implementations.
> I visited the Activity.class. I looked at the "enabled" variable.
> I selected the setEnabled method. I pressed Ctrl-Alt-H to get all the
> Finally, I noticed that setEnabled is package private API an no public API
> seems to lead to it.
> The closest thing to a useful API I saw was in
> Concluding, to me it seems there is no public API to dynamically disable
> an activity (AKA capability). I may be wrong.
> When activities were just introduced, there was this little dialog
> off "Window>" where you could explicitly enable/disable activities.
> It seems to have disappeared now.
Powered by FUDForum
. Page generated in 0.04533 seconds