Skip to main content



      Home
Home » Eclipse Projects » Eclipse Platform » Perspective action
Perspective action [message #93579] Mon, 14 July 2003 19:41 Go to next message
Eclipse UserFriend
Originally posted by: luis_benitez.nospam.us.ibm.com

Hello,

How do I contribute an action so that it only appears when that perspective
is active (open) ? Is there something special that I would do on plugin.xml
?

Thanks,

-Luis
Re: Perspective action [message #93593 is a reply to message #93579] Mon, 14 July 2003 19:51 Go to previous messageGo to next message
Eclipse UserFriend
This is a multipart message in MIME format.
--=_alternative 00832F5485256D63_=
Content-Type: text/plain; charset="US-ASCII"

<extension point="org.eclipse.ui.perspectiveExtensions">
- <perspectiveExtension targetID="your.perspective.id">
<actionSet id="your.actionset.id" />
</perspectiveExtension>
</extension>

-m@

--=_alternative 00832F5485256D63_=
Content-Type: text/html; charset="US-ASCII"


<br><font size=3 color=blue>&nbsp; &nbsp; &nbsp; &nbsp; &lt;</font><font size=3 color=#990000>extension
point</font><font size=3 color=blue>=&quot;</font><font size=3><b>org.eclipse.ui.perspectiveExtensions</b></font ><font size=3 color=blue>&quot;&gt;</font>
<br><a href= file:///C:/AtlantaDev/rcp/demoapp/eclipse/plugins/com.ibm.rc p.demoplugin/plugin.xml#><font size=3 color=red face="Courier New"><b>-</b></font></a><font size=3>
</font><font size=3 color=blue>&lt;</font><font size=3 color=#990000>perspectiveExtension
targetID</font><font size=3 color=blue>=&quot;</font><font size=3><b>your.perspective.id</b></font><font size=3 color=blue>&quot;&gt;</font>
<br><font size=3 color=red face="Courier New"><b>&nbsp;</b></font><font size=3>
</font><font size=3 color=blue>&lt;</font><font size=3 color=#990000>actionSet</font><font size=3>
</font><font size=3 color=#990000>id</font><font size=3 color=blue>=&quot;</font><font size=3><b>your.actionset.id</b></font><font size=3 color=blue>&quot;
/&gt;</font><font size=3> </font>
<br><font size=3 color=red face="Courier New"><b>&nbsp;</b></font><font size=3>
</font><font size=3 color=blue>&lt;/</font><font size=3 color=#990000>perspectiveExtension</font><font size=3 color=blue>&gt;</font>
<br><font size=3 color=red face="Courier New"><b>&nbsp;</b></font><font size=3>
</font><font size=3 color=blue>&lt;/</font><font size=3 color=#990000>extension</font><font size=3 color=blue>&gt;</font>
<br>
<br><font size=2 face="sans-serif">-m@</font>
<br>
--=_alternative 00832F5485256D63_=--
Re: Perspective action [message #93606 is a reply to message #93593] Mon, 14 July 2003 19:54 Go to previous messageGo to next message
Eclipse UserFriend
This is a multipart message in MIME format.
--=_alternative 008377F585256D63_=
Content-Type: text/plain; charset="US-ASCII"

Sorry for the ugly post, this is a little better

<extension point="org.eclipse.ui.perspectiveExtensions">
<perspectiveExtension targetID="your.perspective.id">
<actionSet id="your.actionset.id" />
</perspectiveExtension>
</extension>

-m@

--=_alternative 008377F585256D63_=
Content-Type: text/html; charset="US-ASCII"


<br><font size=2 face="sans-serif">Sorry for the ugly post, this is a little
better</font>
<br>
<br><font size=2 face="sans-serif">&lt;extension point=&quot;org.eclipse.ui.perspectiveExtensions&quo t;&gt;
</font>
<br><font size=2 face="sans-serif">&nbsp; &nbsp; &nbsp; &nbsp; &lt;perspectiveExtension
targetID=&quot;your.perspective.id&quot;&gt; </font>
<br><font size=2 face="sans-serif">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &lt;actionSet id=&quot;your.actionset.id&quot;
/&gt; </font>
<br><font size=2 face="sans-serif">&nbsp; &nbsp; &nbsp; &nbsp; &lt;/perspectiveExtension&gt;
</font>
<br><font size=2 face="sans-serif">&lt;/extension&gt; </font>
<br>
<br><font size=2 face="sans-serif">-m@</font>
<br>
--=_alternative 008377F585256D63_=--
Re: Perspective action [message #93631 is a reply to message #93606] Mon, 14 July 2003 20:18 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: luis_benitez.nospam.us.ibm.com

This is a multi-part message in MIME format.

------=_NextPart_000_000F_01C34A45.0C7E2BA0
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

Hi Matt,

Thanks for the quick response. I tried your suggestion, however, when I =
switch perspectives, the actions still remain. I'm using RCP M7 I =
believe. Here's the code that swithches perspectives, perhaps, I'm =
doing something wrong ?:

if ( action to switchperspective ) {

workbench.showPerspective( "perspectiveID" );
}

Let me know if I'm missing something.

Thanks

-Luis
<Matthew_Hatem@notesdev.ibm.com> wrote in message =
news:bevfr0$698$2@eclipse.org...

Sorry for the ugly post, this is a little better=20

<extension point=3D"org.eclipse.ui.perspectiveExtensions">=20
<perspectiveExtension targetID=3D"your.perspective.id">=20
<actionSet id=3D"your.actionset.id" />=20
</perspectiveExtension>=20
</extension>=20

-m@=20

------=_NextPart_000_000F_01C34A45.0C7E2BA0
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=3D"text/html; =
charset=3Diso-8859-1">
<META content=3D"MSHTML 6.00.2800.1170" name=3DGENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=3D#ffffff>
<DIV><FONT face=3DArial size=3D2>Hi Matt,</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>Thanks for the quick response.&nbsp; I =
tried your=20
suggestion, however, when I switch perspectives, the actions still =
remain.&nbsp;=20
I'm using RCP M7 I believe.&nbsp; Here's the code that swithches =
perspectives,=20
perhaps, I'm doing something wrong ?:</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>if ( action to switchperspective ) =
{</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>&nbsp;&nbsp;&nbsp; =
workbench.showPerspective(=20
"perspectiveID" );</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>}</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>Let me know if I'm missing =
something.</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>-Luis</FONT></DIV>
<BLOCKQUOTE=20
style=3D"PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; =
BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
<DIV>&lt;<A=20
=
href=3D"mailto:Matthew_Hatem@notesdev.ibm.com">Matthew_Hatem@notesdev.ibm=
..com</A>&gt;=20
wrote in message <A=20
=
href=3D"news:bevfr0$698$2@eclipse.org">news:bevfr0$698$2@eclipse.org</A>.=
...</DIV><BR><FONT=20
face=3Dsans-serif size=3D2>Sorry for the ugly post, this is a little =
better</FONT>=20
<BR><BR><FONT face=3Dsans-serif size=3D2>&lt;extension=20
point=3D"org.eclipse.ui.perspectiveExtensions"&gt; </FONT><BR><FONT=20
face=3Dsans-serif size=3D2>&nbsp; &nbsp; &nbsp; &nbsp; =
&lt;perspectiveExtension=20
targetID=3D"your.perspective.id"&gt; </FONT><BR><FONT =
face=3Dsans-serif=20
size=3D2>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; =
&lt;actionSet=20
id=3D"your.actionset.id" /&gt; </FONT><BR><FONT face=3Dsans-serif =
size=3D2>&nbsp;=20
&nbsp; &nbsp; &nbsp; &lt;/perspectiveExtension&gt; </FONT><BR><FONT=20
face=3Dsans-serif size=3D2>&lt;/extension&gt; </FONT><BR><BR><FONT =
face=3Dsans-serif=20
size=3D2>-m@</FONT> <BR></BLOCKQUOTE></BODY></HTML>

------=_NextPart_000_000F_01C34A45.0C7E2BA0--
Re: Perspective action [message #93952 is a reply to message #93631] Tue, 15 July 2003 09:56 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: richkulp.NOSPAM.us.ibm.com

Make sure that on your actionset definition, not the perspective
extension definition, that you don't have visible="true", or to be safe
make it visible="false" (I don't know what the default is). If you have
this it would make it visible in all perspectives.

Rich
Re: Perspective action [message #94141 is a reply to message #93952] Tue, 15 July 2003 13:27 Go to previous message
Eclipse UserFriend
Originally posted by: luis_benitez.nospam.us.ibm.com

Hi Richard,

You hit the nail in the head. When I switch perspectives now, the actions
go away.

Thanks,
-Luis

"Richard L. Kulp" <richkulp@NOSPAM.us.ibm.com> wrote in message
news:bf111p$ms8$1@eclipse.org...
> Make sure that on your actionset definition, not the perspective
> extension definition, that you don't have visible="true", or to be safe
> make it visible="false" (I don't know what the default is). If you have
> this it would make it visible in all perspectives.
>
> Rich
>
Previous Topic:uncommenting system.outs in the workspace
Next Topic:removing workbench menus throws NPE
Goto Forum:
  


Current Time: Mon May 12 03:48:07 EDT 2025

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

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

Back to the top