Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Rich Client Platform (RCP) » Can FindReplaceAction use IFindReplaceTarget.isEditable?
Can FindReplaceAction use IFindReplaceTarget.isEditable? [message #464451] Wed, 07 March 2007 03:08 Go to next message
Peter Nehrer is currently offline Peter NehrerFriend
Messages: 241
Registered: July 2009
Senior Member
Hi,

is there any reason why FindReplaceAction uses the part's
ITextEditorExtension2.isEditorInputModifiable instead of
IFindReplaceTarget.isEditable to determine whether to enable replacing?
In 3.3 it was patched to do just that, but only if used with a Shell and
not IWorkbenchPart. Using IFindReplaceTarget.isEditable would make it
possible to provide Find/Replace support for non-text editors (if they
know how to produce a valid adapter). Any insight would be appreciated.
Thanks.

--Peter
Re: Can FindReplaceAction use IFindReplaceTarget.isEditable? [message #464594 is a reply to message #464451] Mon, 12 March 2007 12:18 Go to previous messageGo to next message
Dani Megert is currently offline Dani MegertFriend
Messages: 3802
Registered: July 2009
Senior Member
Peter Nehrer wrote:

> Hi,
>
> is there any reason why FindReplaceAction uses the part's
> ITextEditorExtension2.isEditorInputModifiable instead of
> IFindReplaceTarget.isEditable to determine whether to enable
> replacing? In 3.3 it was patched to do just that, but only if used
> with a Shell and not IWorkbenchPart. Using
> IFindReplaceTarget.isEditable would make it possible to provide
> Find/Replace support for non-text editors (if they know how to produce
> a valid adapter). Any insight would be appreciated. Thanks.

If the part is a text editor (implements ITextEditorExtension2 to be
more precise) it has to go through the more specific code. I've now
fixed the code to use IFindReplaceTarget.isEditable() if the part isn't
a ITextEditorExtension2.

HTH
Dani

>
> --Peter
Re: Can FindReplaceAction use IFindReplaceTarget.isEditable? [message #464608 is a reply to message #464594] Mon, 12 March 2007 14:43 Go to previous message
Peter Nehrer is currently offline Peter NehrerFriend
Messages: 241
Registered: July 2009
Senior Member
Great, that'll do, thanks!
--Peter
Previous Topic:Launching external editors
Next Topic:How to relaunch the RCP Application?
Goto Forum:
  


Current Time: Thu Sep 19 15:31:22 GMT 2024

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

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

Back to the top