[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Newsgroup Home]
|
[news.eclipse.platform.rcp] Launch Command at startup
|
- From: roel.denijs@xxxxxx (Roel De Nijs)
- Date: Wed, 16 Jul 2008 09:29:49 +0000 (UTC)
- Newsgroups: eclipse.platform.rcp
- Organization: Eclipse
- User-agent: NewsPortal/0.36 (http://florian-amrhein.de/newsportal)
Hi all,
I have a toolbar with a command (style = toggle). snippet from plugin.xml
<menuContribution locationURI="toolbar:org.eclipse.ui.main.toolbar">
<toolbar id="be.aclvb.demo.ui.toolbars.main">
<command
commandId="org.eclipse.ui.file.toggle.navigation"
icon="icons/tree.gif"
label="SHOW NAVIGATION"
style="toggle">
</command>
</toolbar>
</menuContribution>
when user hits the button first time, a view has to be shown. when he hits
it a second time, same view has to hide.
So i created a handler that shows and hides the view, and also updates the
label of the button in the toolbar with implementing the IElementUpdater.
and when i click on the button (several times) everything works fine.
But at startup the view has to be shown, so i want to invoke the command
at startup of my rcp application. how can i achieve this?
Thanks already!
Regards,
Roel