Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Rich Client Platform (RCP) » org.eclipse.ui.edit.copy NotHandledException
org.eclipse.ui.edit.copy NotHandledException [message #485358] Fri, 11 September 2009 13:44 Go to next message
Stewart Francis is currently offline Stewart FrancisFriend
Messages: 9
Registered: July 2009
Junior Member
Hi,

Eclipse 3.4.2/linux

I've included the org.eclipse.ui.edit.copy action in my application, and
supplied my own handler, which is working fine. However, I'm having
problems when the default handler (WidgetMethodHandler) is used. The
copy action in the Edit menu is always enabled, whenever this handler is
being used, regardless of whether or not the handler's isHandled()
evaluates to true.

When the copy command is executed, the isHandled() is checked, returns
false, so the handler isn't used and a NotHandledException is thrown.

This behaviour can be reproduced in eclipse 3.4.2/linux via the
following actions:

Open a plugin.xml editor, select the overview tab, in the outline view
select "overview", in the Edit menu select copy, check the error log.

I've tried to reproduce this on eclipse 3.5/windows/linux and it doesn't
seem to happen (although I've not debugged to find out why).

Is this a 3.4.2 bug? Is there a workaround?

Thanks in advance,

Stew
Re: org.eclipse.ui.edit.copy NotHandledException [message #485371 is a reply to message #485358] Fri, 11 September 2009 14:06 Go to previous messageGo to next message
Paul Webster is currently offline Paul WebsterFriend
Messages: 6859
Registered: July 2009
Location: Ottawa
Senior Member

Stewart Francis wrote on Fri, 11 September 2009 09:44

Is this a 3.4.2 bug? Is there a workaround?




See the discussion in http://www.eclipse.org/forums/index.php?t=msg&th=153761

In 3.4.x only part of the ActionFactory actions were converted to commands. Any ActionFactory actions that return RetargetActions need to be replaced with CommandContributionItems.

PW


Re: org.eclipse.ui.edit.copy NotHandledException [message #485587 is a reply to message #485371] Mon, 14 September 2009 00:20 Go to previous message
Stewart Francis is currently offline Stewart FrancisFriend
Messages: 9
Registered: July 2009
Junior Member
Paul Webster wrote:
> Stewart Francis wrote on Fri, 11 September 2009 09:44
>> Is this a 3.4.2 bug? Is there a workaround?
>
>
> See the discussion in
> http://www.eclipse.org/forums/index.php?t=msg&th=153761
>
> In 3.4.x only part of the ActionFactory actions were converted to
> commands. Any ActionFactory actions that return RetargetActions need to
> be replaced with CommandContributionItems.
>
> PW
>

Thanks for the response Paul. I incorrectly indicated in my original
post that I was using the copy action in my application. I'm actually
using the org.eclipse.ui.edit.copy command (adding the command using the
org.eclipse.ui.menus extension point). I tried out the solution you
posted in the linked thread but got exactly the same result. I'm
guessing these are two ways of achieving the same thing?

Stew
Previous Topic:How do I get control on Window->Open Perspective menu item
Next Topic:Traverse to get all children
Goto Forum:
  


Current Time: Fri Apr 26 19:29:44 GMT 2024

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

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

Back to the top