Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Rich Client Platform (RCP) » Disable Extension Points of Required Plug-ins
Disable Extension Points of Required Plug-ins [message #465135] Fri, 23 March 2007 11:15 Go to next message
Eclipse UserFriend
Originally posted by: qsi.nerotech.ch

Hello everybody

I got a little question: If I set some plug-ins like org.eclipse.ui as required plug-ins, there are extension points I don't want to show up. For example the default Key-Binding Scheme or some export-wizard-pages. I try to disable them but I have no idea how to do that. After googling for solutions for a long time without success i decided to post my question here. Does anybody have an idea how to do this?

Thanks a lot for your help!

Markus
Re: Disable Extension Points of Required Plug-ins [message #465149 is a reply to message #465135] Fri, 23 March 2007 13:12 Go to previous messageGo to next message
Alex Blewitt is currently offline Alex BlewittFriend
Messages: 946
Registered: July 2009
Senior Member
You've got a few choices:

1) Edit the org.eclipse.ui plugin and remove the unwanted extensions from plugin.xml. Easiest, but you have to do it each time org.eclipse.ui is updated.

2) Copy the code out from org.eclipse.ui into org.yourown.plugin and use that instead. More difficult, plus you still have to do it each time.

3) Look at the plugin.xml transformation code that Kim was working on http://eclipse.pookzilla.net/2006/10/context-capability-and- perspective.php

I suspect there might be more information available, but AFAIK it was in the incubator and hasn't made it out to the 3.3 stream instead.

Alex.
Re: Disable Extension Points of Required Plug-ins [message #465153 is a reply to message #465135] Fri, 23 March 2007 14:36 Go to previous messageGo to next message
No real name is currently offline No real nameFriend
Messages: 38
Registered: July 2009
Member
I do this with activities extensions in my core plugin descriptor.
Here's what it looks like:

<extension
point="org.eclipse.ui.activities">
<activity
id="com.myCompany.xxxxx"
name="Hidden activities"/>
<activityPatternBinding
activityId="com.myCompany.xxxxx"
pattern="org.eclipse.ui.ide/org.eclipse.update.ui.*"/>
<activityPatternBinding
activityId="com.myCompany.xxxxx"
pattern="org.eclipse.ui.ide/.*WorkingSet.*"/>
</extension>

Some notes: the <activity id="com.myCompany.xxxxx" defines an activity
ID. I purposely use an ID of an extension that will never be used/started.

Then, I use that ID in subsequent <activityPatternBinding elements. The
'pattern="xxx"' attributes define extensions of plugins that will be
enabled/visible only when my activity ID is enabled/visible. Since the
ID of my activity ID will never be enabled/visible, neither will the
Elipse-based extensions.

Works slick. But you have to peruse the various Eclipse plugins to
determine the extensions to disable. That takes a bit of time....

RN

Markus Neuenschwander wrote:
> Hello everybody
>
> I got a little question: If I set some plug-ins like org.eclipse.ui as required plug-ins, there are extension points I don't want to show up. For example the default Key-Binding Scheme or some export-wizard-pages. I try to disable them but I have no idea how to do that. After googling for solutions for a long time without success i decided to post my question here. Does anybody have an idea how to do this?
>
> Thanks a lot for your help!
>
> Markus
Re: Disable Extension Points of Required Plug-ins [message #465259 is a reply to message #465153] Tue, 27 March 2007 08:47 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: qsi.nerotech.ch

Thanks a lot for your help.

I tried it and it worked well for the wizards. But I'm stuck with the default key-binding-schemes. I added something like this to my plugin.xml:

<activityPatternBinding
activityId="my.activity"
pattern=" org\.eclipse\.ui/org\.eclipse\.ui\.defaultAcceleratorConfigu ration "/>

Is there an error in this xml? I can't understand why this doesn't work...

Thanks for any advice.

Markus
Re: Disable Extension Points of Required Plug-ins [message #465270 is a reply to message #465259] Tue, 27 March 2007 18:02 Go to previous messageGo to next message
Paul Webster is currently offline Paul WebsterFriend
Messages: 6859
Registered: July 2009
Location: Ottawa
Senior Member

activity pattern bindings don't apply to keybindings, AFAIK.

If you don't want any eclipse keybindings in your RCP app, create your
own scheme. You can use a preference constant and the
plugin_customization.ini trick to make that the default for your RCP app.

Then you can define all of the keybindings you want in your new scheme.

Later,
PW


Re: Disable Extension Points of Required Plug-ins [message #465278 is a reply to message #465270] Wed, 28 March 2007 06:45 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: qsi.nerotech.ch

OK. Thanks. But this solution doesn't really solve my problem. I have my own scheme already and set as default. But I'd like to let the user change the key-bindings with the key-binding preference page. But there I can select the two default key-binding schemes. Any idea how to disable them? Is there any?

Thanks a lot.
Re: Disable Extension Points of Required Plug-ins [message #465331 is a reply to message #465278] Wed, 28 March 2007 16:34 Go to previous messageGo to next message
Paul Webster is currently offline Paul WebsterFriend
Messages: 6859
Registered: July 2009
Location: Ottawa
Senior Member

in 3.3 you can use the product customization abilities to remove XML
declarations from consideration.
http://wiki.eclipse.org/index.php/Product_Customization

In 3.2, if you show the keys preference page they can choose the other
schemes available.

Later,
PW


Re: Disable Extension Points of Required Plug-ins [message #465418 is a reply to message #465331] Thu, 29 March 2007 07:44 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: qsi.nerotech.ch

OK. I tried it. I wrote a xslt file that should work. But how to I add this to the org.eclipse.ui plugin? The whole transformations-stuff seems do be quite new and not so well documented. So any help here? Is there a property I can set? Or do I have to do it by code? Thanks a lot and sorry for bothering you...
Re: Disable Extension Points of Required Plug-ins [message #465480 is a reply to message #465418] Thu, 29 March 2007 15:58 Go to previous messageGo to next message
Paul Webster is currently offline Paul WebsterFriend
Messages: 6859
Registered: July 2009
Location: Ottawa
Senior Member

You have to follow the instructions in :

http://wiki.eclipse.org/index.php/Equinox_Transforms

If you check out the examples, it must explain how to tell your RCP
program to run the transforms.

Later,
PW


Re: Disable Extension Points of Required Plug-ins [message #465497 is a reply to message #465480] Fri, 30 March 2007 09:56 Go to previous message
Eclipse UserFriend
Originally posted by: qsi.nerotech.ch

OK. I'll have a lock at that. But I'm struggling with other problems right now and this issue is not A-priority.

Thanks a lot guys. Well done ;)
Previous Topic:update top level menu
Next Topic:Undo for Eclipse RCP Editor by Using ActionFactory.UNDO.create(window)
Goto Forum:
  


Current Time: Tue Apr 16 14:19:11 GMT 2024

Powered by FUDForum. Page generated in 0.90965 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top