|
|
Re: Dynamic menu contribution doesn't show up in a toolbar [message #710528 is a reply to message #709974] |
Fri, 05 August 2011 05:41 |
|
This works for me:
<menuContribution locationURI="toolbar:org.eclipse.ui.main.toolbar">
<toolbar id="com.gcsf.books.toolbar.edit">
... some contributions here ...
</toolbar>
<toolbar id="com.gcsf.books.toolbar.view">
<dynamic class="com.gcsf.books.contributions.ToolbarPerspectiveSwitcherMenu"
id="com.gcsf.books.dynamic.toolbar.perspectiveSwitcherMenu">
</dynamic>
</toolbar>
</menuContribution>
The stackoverflow response was correct: the menu and toolbar can't be contributed to a toolbar. But a toolbar can be contributed to a menu contribution.
In your case the <dynamic> has to be directly under <toolbar> (see my example above).
Just read the extension point description for 'org.eclipse.ui.menus' and you will see how this extension point has to be defined.
Time is what you make of it.
|
|
|
|
Powered by
FUDForum. Page generated in 0.03316 seconds