Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Rich Client Platform (RCP) » How to remove the default "project"/"example"/"other" item from the ne(common wizard, common navigation, right click menu)
How to remove the default "project"/"example"/"other" item from the ne [message #502120] Sun, 06 December 2009 03:55 Go to next message
abalest lanclot is currently offline abalest lanclotFriend
Messages: 6
Registered: December 2009
Junior Member
Currently, I'm working on the common navigation framework to make my own viewer.

However, as I successfully accomplished my work by implements serveal common wizard item(under new wizard category), I found that there's always the "Project"/"Example"/"Other" item displaying with my new wizard item when right click in the my viewer.
I've tried to remove the three items but end in vain. I've used the extension point "org.eclipse.ui.activitise " mentioned in topic " http://dev.eclipse.org/newslists/news.eclipse.platform.rcp/m sg36794.html", but it only remove the item in new wizard dialog.

I am wondering how could I remove these item from my right click wizard menu. Any advice are welcomed.
Re: How to remove the default "project"/"example"/"other" item from th [message #502173 is a reply to message #502120] Sun, 06 December 2009 22:03 Go to previous messageGo to next message
Francis Upton IV is currently offline Francis Upton IVFriend
Messages: 472
Registered: July 2009
Location: Oakland, CA
Senior Member
In your viewerActionBinding element you are probably doing something like this:

       <viewerActionBinding
            viewerId="org.eclipse.ui.navigator.ProjectExplorer">
         <includes>
             <actionExtension pattern="org.eclipse.ui.navigator.resources.*" />
         </includes>


You don't want the org.eclipse.ui.navigator.resources.NewActions as that adds the undesirable items. You will probably need to copy this code and make your own NewActions which does not have this.

If I were you, I would file a bug complaining about the need to do this simply to remove these items. It seems like too much work.


Re: How to remove the default "project"/"example"/"other" item from th [message #502471 is a reply to message #502173] Tue, 08 December 2009 12:47 Go to previous message
abalest lanclot is currently offline abalest lanclotFriend
Messages: 6
Registered: December 2009
Junior Member
Hi Francis,

I tried to remove the following code you metioned.
       <viewerActionBinding
            viewerId="org.eclipse.ui.navigator.ProjectExplorer">
         <includes>
             <actionExtension pattern="org.eclipse.ui.navigator.resources.*" />
         </includes>


Then, the new action group and other action group are gone. Seems like what I need.
I browse the source code of org.eclipse.ui.navigator.resources and found there's a newactionprovider and there's the code which adds NewProjectAction & NewExampleAction. Using a customized NewActionProvider may help to solve my problem.

Thanks for your advice.

And bug 297190 is created for this.
Previous Topic:Run configuration plug-in auto-start setting has no effect. Why?
Next Topic:Opening an external editor from a Editor Descriptor
Goto Forum:
  


Current Time: Fri Apr 26 02:33:35 GMT 2024

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

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

Back to the top