Skip to main content



      Home
Home » Eclipse Projects » Eclipse Platform » MultipageEditorPart
MultipageEditorPart [message #323798] Tue, 08 January 2008 21:23 Go to next message
Eclipse UserFriend
Originally posted by: sandip.sahoo1980.gmail.com

Hi,

I am implementing MultipageEditorPart. Whether it is possible to know
whether the Editor is open/active or not inside the EditorPart? As far as I
know there is no such API provided such as isActive().

Would anybody please provide me any solution for the above?

Regards,
Sandip
Re: MultipageEditorPart [message #323805 is a reply to message #323798] Wed, 09 January 2008 02:59 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: merks.ca.ibm.com

This is a multi-part message in MIME format.
--------------030300030607020903070706
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit

Sandip,

Using the type of technique below within an editor, you can monitor
activation and deactivation of your editor. Maybe you can test
"getSite().getPage().getActiveEditor() == this" but I'm not sure if
that's true when the editor doesn't have focus...

protected IPartListener partListener =
new IPartListener()
{
public void partActivated(IWorkbenchPart p)
{
if (p instanceof ContentOutline)
{
if (((ContentOutline)p).getCurrentPage() == contentOutlinePage)
{
getActionBarContributor().setActiveEditor(LibraryEditor.this );

setCurrentViewer(contentOutlineViewer);
}
}
else if (p instanceof PropertySheet)
{
if (((PropertySheet)p).getCurrentPage() == propertySheetPage)
{
getActionBarContributor().setActiveEditor(LibraryEditor.this );
handleActivate();
}
}
else if (p == LibraryEditor.this)
{
handleActivate();
}
}
public void partBroughtToTop(IWorkbenchPart p)
{
// Ignore.
}
public void partClosed(IWorkbenchPart p)
{
// Ignore.
}
public void partDeactivated(IWorkbenchPart p)
{
// Ignore.
}
public void partOpened(IWorkbenchPart p)
{
// Ignore.
}
};


public void init(IEditorSite site, IEditorInput editorInput)
{
setSite(site);
setInputWithNotify(editorInput);
setPartName(editorInput.getName());
site.setSelectionProvider(this);
site.getPage().addPartListener(*partListener*);
}


public void dispose()
{
updateProblemIndication = false;

getSite().getPage().removePartListener(*partListener*);

adapterFactory.dispose();

if (getActionBarContributor().getActiveEditor() == this)
{
getActionBarContributor().setActiveEditor(null);
}

if (propertySheetPage != null)
{
propertySheetPage.dispose();
}

if (contentOutlinePage != null)
{
contentOutlinePage.dispose();
}

super.dispose();
}


Sandip Sahoo wrote:
> Hi,
>
> I am implementing MultipageEditorPart. Whether it is possible to know
> whether the Editor is open/active or not inside the EditorPart? As far as I
> know there is no such API provided such as isActive().
>
> Would anybody please provide me any solution for the above?
>
> Regards,
> Sandip
>
>
>


--------------030300030607020903070706
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000000">
Sandip,<br>
<br>
Using the type of technique below within an editor, you can monitor
activation and deactivation of your editor.&nbsp; Maybe you can test
"getSite().getPage().getActiveEditor() == this" but I'm not sure if
that's true when the editor doesn't have focus...<br>
<br>
<small>&nbsp; protected IPartListener partListener =<br>
&nbsp;&nbsp;&nbsp; new IPartListener()<br>
&nbsp;&nbsp;&nbsp; {<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; public void partActivated(IWorkbenchPart p)<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; if (p instanceof ContentOutline)<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; {<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; if (((ContentOutline)p).getCurrentPage() ==
contentOutlinePage)<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; {<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
getActionBarContributor().setActiveEditor(LibraryEditor.this ); <br>
<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; setCurrentViewer(contentOutlineViewer);<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; }<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; }<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; else if (p instanceof PropertySheet)<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; {<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; if (((PropertySheet)p).getCurrentPage() == propertySheetPage)<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; {<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
getActionBarContributor().setActiveEditor(LibraryEditor.this ); <br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; handleActivate();<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; }<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; }<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; else if (p == LibraryEditor.this)<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; {<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; handleActivate();<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; }<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; }<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; public void partBroughtToTop(IWorkbenchPart p)<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; // Ignore.<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; }<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; public void partClosed(IWorkbenchPart p)<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; // Ignore.<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; }<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; public void partDeactivated(IWorkbenchPart p)<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; // Ignore.<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; }<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; public void partOpened(IWorkbenchPart p)<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; // Ignore.<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; }<br>
&nbsp;&nbsp;&nbsp; };</small><br>
<br>
<br>
<small>&nbsp; public void init(IEditorSite site, IEditorInput editorInput)<br>
&nbsp; {<br>
&nbsp;&nbsp;&nbsp; setSite(site);<br>
&nbsp;&nbsp;&nbsp; setInputWithNotify(editorInput);<br>
&nbsp;&nbsp;&nbsp; setPartName(editorInput.getName());<br>
&nbsp;&nbsp;&nbsp; site.setSelectionProvider(this);<br>
&nbsp;&nbsp;&nbsp; site.getPage().addPartListener(<b>partListener</b>);<br >
&nbsp; }<br>
</small><br>
<br>
<small>&nbsp; public void dispose()<br>
&nbsp; {<br>
&nbsp;&nbsp;&nbsp; updateProblemIndication = false;<br>
<br>
&nbsp;&nbsp;&nbsp; getSite().getPage().removePartListener(<b>partListener</b >);<br>
<br>
&nbsp;&nbsp;&nbsp; adapterFactory.dispose();<br>
<br>
&nbsp;&nbsp;&nbsp; if (getActionBarContributor().getActiveEditor() == this)<br>
&nbsp;&nbsp;&nbsp; {<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; getActionBarContributor().setActiveEditor(null);<br>
&nbsp;&nbsp;&nbsp; }<br>
<br>
&nbsp;&nbsp;&nbsp; if (propertySheetPage != null)<br>
&nbsp;&nbsp;&nbsp; {<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; propertySheetPage.dispose();<br>
&nbsp;&nbsp;&nbsp; }<br>
<br>
&nbsp;&nbsp;&nbsp; if (contentOutlinePage != null)<br>
&nbsp;&nbsp;&nbsp; {<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; contentOutlinePage.dispose();<br>
&nbsp;&nbsp;&nbsp; }<br>
<br>
&nbsp;&nbsp;&nbsp; super.dispose();<br>
&nbsp; }</small><br>
<br>
<br>
Sandip Sahoo wrote:
<blockquote cite="mid:fm1b7m$4r6$1@build.eclipse.org" type="cite">
<pre wrap="">Hi,

I am implementing MultipageEditorPart. Whether it is possible to know
whether the Editor is open/active or not inside the EditorPart? As far as I
know there is no such API provided such as isActive().

Would anybody please provide me any solution for the above?

Regards,
Sandip


</pre>
</blockquote>
<br>
</body>
</html>

--------------030300030607020903070706--
Re: MultipageEditorPart [message #323809 is a reply to message #323798] Wed, 09 January 2008 04:17 Go to previous messageGo to next message
Eclipse UserFriend
PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActi vePage().getActiveEditor();
returns the active editor.
PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActi vePage().getEditorReferences();
returns an array of references to open editors.

Snjeza

Sandip Sahoo wrote:
> Hi,
>
> I am implementing MultipageEditorPart. Whether it is possible to know
> whether the Editor is open/active or not inside the EditorPart? As far as I
> know there is no such API provided such as isActive().
>
> Would anybody please provide me any solution for the above?
>
> Regards,
> Sandip
>
>
Re: MultipageEditorPart [message #323839 is a reply to message #323805] Wed, 09 January 2008 13:25 Go to previous message
Eclipse UserFriend
Originally posted by: sandip.sahoo1980.gmail.com

This is a multi-part message in MIME format.

------=_NextPart_000_0015_01C852A9.FE748960
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

Hi Ed,

Thanks.

Itz working.
Even I have tried with below. seems working also.
@Override

public void setFocus() {

super.setFocus();

}

Regards,

Sandip

"Ed Merks" <merks@ca.ibm.com> wrote in message =
news:fm1uos$9v2$1@build.eclipse.org...
Sandip,

Using the type of technique below within an editor, you can monitor =
activation and deactivation of your editor. Maybe you can test =
"getSite().getPage().getActiveEditor() =3D=3D this" but I'm not sure if =
that's true when the editor doesn't have focus...

protected IPartListener partListener =3D
new IPartListener()
{
public void partActivated(IWorkbenchPart p)
{
if (p instanceof ContentOutline)
{
if (((ContentOutline)p).getCurrentPage() =3D=3D =
contentOutlinePage)
{
=
getActionBarContributor().setActiveEditor(LibraryEditor.this );

setCurrentViewer(contentOutlineViewer);
}
}
else if (p instanceof PropertySheet)
{
if (((PropertySheet)p).getCurrentPage() =3D=3D =
propertySheetPage)
{
=
getActionBarContributor().setActiveEditor(LibraryEditor.this );
handleActivate();
}
}
else if (p =3D=3D LibraryEditor.this)
{
handleActivate();
}
}
public void partBroughtToTop(IWorkbenchPart p)
{
// Ignore.
}
public void partClosed(IWorkbenchPart p)
{
// Ignore.
}
public void partDeactivated(IWorkbenchPart p)
{
// Ignore.
}
public void partOpened(IWorkbenchPart p)
{
// Ignore.
}
};


public void init(IEditorSite site, IEditorInput editorInput)
{
setSite(site);
setInputWithNotify(editorInput);
setPartName(editorInput.getName());
site.setSelectionProvider(this);
site.getPage().addPartListener(partListener);
}


public void dispose()
{
updateProblemIndication =3D false;

getSite().getPage().removePartListener(partListener);

adapterFactory.dispose();

if (getActionBarContributor().getActiveEditor() =3D=3D this)
{
getActionBarContributor().setActiveEditor(null);
}

if (propertySheetPage !=3D null)
{
propertySheetPage.dispose();
}

if (contentOutlinePage !=3D null)
{
contentOutlinePage.dispose();
}

super.dispose();
}


Sandip Sahoo wrote:=20
Hi,

I am implementing MultipageEditorPart. Whether it is possible to know=20
whether the Editor is open/active or not inside the EditorPart? As far =
as I=20
know there is no such API provided such as isActive().

Would anybody please provide me any solution for the above?

Regards,
Sandip=20


=20

------=_NextPart_000_0015_01C852A9.FE748960
Content-Type: text/html;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=3DContent-Type =
content=3Dtext/html;charset=3DISO-8859-1>
<META content=3D"MSHTML 6.00.2900.3157" name=3DGENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY text=3D#000000 bgColor=3D#ffffff>
<DIV><FONT face=3DArial size=3D2>Hi Ed,</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>Thanks.</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>Itz&nbsp;working.</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>Even I have tried with below. seems =
working=20
also.</FONT></DIV>
<DIV><FONT color=3D#646464 size=3D2>
<P align=3Dleft>@Override</P></FONT><FONT size=3D2>
<P align=3Dleft></FONT><B><FONT color=3D#7f0055 =
size=3D2>public</B></FONT><FONT=20
size=3D2> </FONT><B><FONT color=3D#7f0055 size=3D2>void</B></FONT><FONT =
size=3D2>=20
setFocus() {</P>
<P align=3Dleft></FONT><B><FONT color=3D#7f0055 =
size=3D2>super</B></FONT><FONT=20
size=3D2>.setFocus();</P>
<P>}</P>
<P><FONT face=3DArial>Regards,</FONT></P>
<P><FONT face=3DArial>Sandip</FONT></P></FONT></DIV>
<BLOCKQUOTE=20
style=3D"PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; =
BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
<DIV>"Ed Merks" &lt;<A =
href=3D"mailto:merks@ca.ibm.com">merks@ca.ibm.com</A>&gt;=20
wrote in message <A=20
=
href=3D"news:fm1uos$9v2$1@build.eclipse.org">news:fm1uos$9v2$1@build.ecli=
pse.org</A>...</DIV>Sandip,<BR><BR>Using=20
the type of technique below within an editor, you can monitor =
activation and=20
deactivation of your editor.&nbsp; Maybe you can test=20
"getSite().getPage().getActiveEditor() =3D=3D this" but I'm not sure =
if that's=20
true when the editor doesn't have focus...<BR><BR><SMALL>&nbsp; =
protected=20
IPartListener partListener =3D<BR>&nbsp;&nbsp;&nbsp; new=20
IPartListener()<BR>&nbsp;&nbsp;&nbsp; =
{<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;=20
public void partActivated(IWorkbenchPart =
p)<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;=20
{<BR> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; if (p instanceof=20
ContentOutline)<BR> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;=20
{<BR> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; if=20
(((ContentOutline)p).getCurrentPage() =3D=3D=20
=
contentOutlinePage)<BR> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&n=
bsp;=20
=
{<BR> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;=20
=
getActionBarContributor().setActiveEditor(LibraryEditor.this ); <BR><BR>&nb=
sp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nb sp;&nbsp;&nbsp;&nbsp;&nbsp;=20
=
setCurrentViewer(contentOutlineViewer);<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;=
&nbsp;&nbsp;&nbsp;&nbsp;=20
}<BR> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;=20
}<BR> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; else if (p instanceof=20
PropertySheet)<BR> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;=20
{<BR> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; if=20
(((PropertySheet)p).getCurrentPage() =3D=3D=20
=
propertySheetPage)<BR> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nb=
sp;=20
=
{<BR> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;=20
=
getActionBarContributor().setActiveEditor(LibraryEditor.this ); <BR>&nbsp;&=
nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;& nbsp;&nbsp;&nbsp;&nbsp;=20
=
handleActivate();<BR> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbs=
p;=20
}<BR> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;=20
}<BR> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; else if (p =3D=3D=20
LibraryEditor.this)<BR> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;=20
{<BR> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;=20
handleActivate();<BR> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;=20
}<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; =
}<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; public=20
void partBroughtToTop(IWorkbenchPart =
p)<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;=20
{<BR> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; //=20
Ignore.<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; =
}<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;=20
public void partClosed(IWorkbenchPart =
p)<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;=20
{<BR> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; //=20
Ignore.<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; =
}<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;=20
public void partDeactivated(IWorkbenchPart=20
p)<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;=20
{<BR> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; //=20
Ignore.<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; =
}<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;=20
public void partOpened(IWorkbenchPart =
p)<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;=20
{<BR> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; //=20
Ignore.<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; }<BR>&nbsp;&nbsp;&nbsp;=20
};</SMALL><BR><BR><BR><SMALL>&nbsp; public void init(IEditorSite site, =

IEditorInput editorInput)<BR>&nbsp; {<BR>&nbsp;&nbsp;&nbsp;=20
setSite(site);<BR>&nbsp;&nbsp;&nbsp;=20
setInputWithNotify(editorInput);<BR>&nbsp;&nbsp;&nbsp;=20
setPartName(editorInput.getName());<BR>&nbsp;&nbsp;&nbsp;=20
site.setSelectionProvider(this);<BR>&nbsp;&nbsp;&nbsp;=20
site.getPage().addPartListener(<B>partListener</B>);<BR >&nbsp;=20
}<BR></SMALL><BR><BR><SMALL>&nbsp; public void dispose()<BR>&nbsp;=20
{<BR>&nbsp;&nbsp;&nbsp; updateProblemIndication =3D=20
false;<BR><BR>&nbsp;&nbsp;&nbsp;=20
=
getSite().getPage().removePartListener(<B>partListener</B >);<BR><BR>&nbsp=
;&nbsp;&nbsp;=20
adapterFactory.dispose();<BR><BR>&nbsp;&nbsp;&nbsp; if=20
(getActionBarContributor().getActiveEditor() =3D=3D =
this)<BR>&nbsp;&nbsp;&nbsp;=20
{<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;=20
getActionBarContributor().setActiveEditor(null);<BR>&nbsp;&nbsp;&nbsp; =

}<BR><BR>&nbsp;&nbsp;&nbsp; if (propertySheetPage !=3D=20
null)<BR>&nbsp;&nbsp;&nbsp; {<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;=20
propertySheetPage.dispose();<BR>&nbsp;&nbsp;&nbsp; =
}<BR><BR>&nbsp;&nbsp;&nbsp;=20
if (contentOutlinePage !=3D null)<BR>&nbsp;&nbsp;&nbsp;=20
{<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;=20
contentOutlinePage.dispose();<BR>&nbsp;&nbsp;&nbsp;=20
}<BR><BR>&nbsp;&nbsp;&nbsp; super.dispose();<BR>&nbsp;=20
}</SMALL><BR><BR><BR>Sandip Sahoo wrote:=20
<BLOCKQUOTE cite=3Dmid:fm1b7m$4r6$1@build.eclipse.org =
type=3D"cite"><PRE wrap=3D"">Hi,

I am implementing MultipageEditorPart. Whether it is possible to know=20
whether the Editor is open/active or not inside the EditorPart? As far =
as I=20
know there is no such API provided such as isActive().

Would anybody please provide me any solution for the above?

Regards,
Sandip=20


</PRE></BLOCKQUOTE><BR></BLOCKQUOTE></BODY></HTML>

------=_NextPart_000_0015_01C852A9.FE748960--
Previous Topic:Programmatically add a file to a project
Next Topic:viewShortcut and Key Bindings
Goto Forum:
  


Current Time: Sat Jul 12 00:06:02 EDT 2025

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

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

Back to the top