ExtensionContributionFactory toolbar contributions [message #1183425] |
Tue, 12 November 2013 16:29  |
Eclipse User |
|
|
|
While trying to use the ExtensionContributionfactory extension , I saw the
behavior exhibited in
(https://bugs.eclipse.org/bugs/show_bug.cgi?id=410426#c2) namely that the
contribution items that I add thru do not respect the visibleWhen Expression
added with the contribution. What I am trying to build is a toolbar item
with a pulldown menu (IMenuCreator) that is populated dynamically, since the
contents need to be populated with information only available at runtime.
The contribution item, should only be active for certain perspectives. Is
there another in which to do this?
I seem to be stuck with:
- I can add static items that respect the expression in plugin.xml (but do
not have the dropdown behavior) and I can add dynamic items thru the
ExtensionContributionfactory , but those do not respect the expression .
|
|
|
Re: ExtensionContributionFactory toolbar contributions [message #1184611 is a reply to message #1183425] |
Wed, 13 November 2013 10:19  |
Eclipse User |
|
|
|
Found another way, implement a dynamic item as a child of the toolbar item
to populate the dynamic entries and then use IElementUpdater on the main
toolbar entry to adjust the tool-tip accordingly (text of the last run entry
from the dropdown, since that becomes the default for toolbar button,
similar to how the debug/run menus work in eclipse)
"Drew" <drew@xxxxxxxx> wrote in message news:l5u6jj$auo$1@xxxxxxxxe.org...
> While trying to use the ExtensionContributionfactory extension , I saw the
> behavior exhibited in
> (https://bugs.eclipse.org/bugs/show_bug.cgi?id=410426#c2) namely that the
> contribution items that I add thru do not respect the visibleWhen
> Expression added with the contribution. What I am trying to build is a
> toolbar item with a pulldown menu (IMenuCreator) that is populated
> dynamically, since the contents need to be populated with information only
> available at runtime. The contribution item, should only be active for
> certain perspectives. Is there another in which to do this?
>
> I seem to be stuck with:
> - I can add static items that respect the expression in plugin.xml (but do
> not have the dropdown behavior) and I can add dynamic items thru the
> ExtensionContributionfactory , but those do not respect the expression .
>
>
|
|
|
Powered by
FUDForum. Page generated in 0.12432 seconds