Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Eclipse Platform » Common Navigator - over-ride double-click behaviour
Common Navigator - over-ride double-click behaviour [message #765081] Tue, 13 December 2011 11:31 Go to next message
Mark Walters is currently offline Mark WaltersFriend
Messages: 25
Registered: June 2011
Junior Member
Hi,
in my Common Navigator class implementation I can use GetCommonViewer to get the CommonViewer class but I can't remove any of the double-click listeners as there's no getListeners method.

I can easily add a new double-click listener but I want to totally replace the double-click listeners that already exist as I don't always want the nodes of my tree to expand when I double-click.

How can I do this?
Any ideas?

Thanks,
Mark.
Re: Common Navigator - over-ride double-click behaviour [message #765769 is a reply to message #765081] Wed, 14 December 2011 16:43 Go to previous messageGo to next message
John B is currently offline John BFriend
Messages: 18
Registered: November 2011
Junior Member
I need to do the same thing and have not implemented or tried what I'm about to suggest but this is the course of action I will be taking:

In your org.eclipse.ui.navigator.viewer extension viewerActionBinding remove org.eclipsze.ui.navigator.resources.* (actionExtension) and put in the individual actionProviders that you want from org.eclipse.ui.navigator.resources (i.e. GotoActionProvider, GoIntoActionProvider, etc.) but do not include OpenActionProvider instead create your own OpenActionProvider.

[Updated on: Wed, 14 December 2011 16:45]

Report message to a moderator

Re: Common Navigator - over-ride double-click behaviour [message #767024 is a reply to message #765769] Fri, 16 December 2011 21:57 Go to previous messageGo to next message
Mark Walters is currently offline Mark WaltersFriend
Messages: 25
Registered: June 2011
Junior Member
Awesome thanks for that- a really good approach- I'll give it a go asap

Ta
Mark
Re: Common Navigator - over-ride double-click behaviour [message #825143 is a reply to message #767024] Tue, 20 March 2012 14:23 Go to previous messageGo to next message
Mark Walters is currently offline Mark WaltersFriend
Messages: 25
Registered: June 2011
Junior Member
hmm, no that's not it at all. The OpenAction just controls the options in the context menus.
Re: Common Navigator - over-ride double-click behaviour [message #825152 is a reply to message #825143] Tue, 20 March 2012 14:37 Go to previous message
Mark Walters is currently offline Mark WaltersFriend
Messages: 25
Registered: June 2011
Junior Member
Got it, Common Navigator has:
protected void handleDoubleClick(DoubleClickEvent anEvent) {

just override in your CommonNavigator class.
Previous Topic:Problems with installing software into eclipse based program
Next Topic:Why ErrorDialog is not showing exception's stack trace from IStatus?
Goto Forum:
  


Current Time: Sat Nov 29 05:38:59 GMT 2014

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

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