Skip to main content

Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Eclipse Platform » 'branding' at run time
'branding' at run time [message #490630] Fri, 09 October 2009 13:32 Go to next message
Derek is currently offline DerekFriend
Messages: 60
Registered: July 2009

I have a set of plugins that can be shipped in several different
products. I want to change the images/icons that are used by the plugins
based on the product that the plugin is shipped with (and without having
to have a different build of the plugin).

For example, one of my plugins defines a view:
<extension point="org.eclipse.ui.views">

In this example, the view16x16.gif is supplied in the icons/ directory
plugin. However, I'd like to ship all the icons in the branding plugin
and pick them up from there. However, I don't want to hard-code the name
of the branding plugin.

Thus, when the branding is "ProductA" I'd like it to select
ProductA/icons/view16x16.gif, but if the branding is ProductB, I'd like
it to select ProductB/icons/view16x16.

So, I'd like to use something like

Is something like this possible? I need to do it for views, menus,
toolbars etc. I'm happy to write code to do it, if that is possible...


Re: 'branding' at run time [message #492386 is a reply to message #490630] Tue, 20 October 2009 10:34 Go to previous message
Stella Levin is currently offline Stella LevinFriend
Messages: 89
Registered: July 2009
I would try to define icons in the code at runtime, get plugin name via
"public final Bundle getBundle()" method of Plugin class,
Then use the "public String getSymbolicName()" of Bundle interface.
Previous Topic:Force re-evaluation of handler enabledWhen expressions from Handler (eclipse 3.3)
Next Topic:Tracking plugin loading errors?
Goto Forum:

Current Time: Mon May 21 07:27:36 GMT 2018

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

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

Back to the top