|
Re: product.getProperty(IProductConstants.WINDOW_IMAGES) [message #642684 is a reply to message #642668] |
Thu, 02 December 2010 10:44 |
Daniel Krügler Messages: 853 Registered: July 2009 |
Senior Member |
|
|
On 12/2/2010 10:34, Kar wrote:
> Hi all,
> I was using the previous call to get the information defined in the
> product and use the images ...
>
> it was working in 3.5 galileo perfectly. Now in 3.6.1 the method returns
> a sequence of names with starting with the name of the plugin
>
> 3.5
> icons/icon-16.gif,icons/icon-32.gif,icons/icon-48.gif
>
> 3.6
> /WorkbenchPlugin/icons/icon-16.gif, /WorkbenchPlugin/icons/icon-32.gif,
> /WorkbenchPlugin/icons/icon-48.gif
>
>
> from 3.6 and from the product object is there a way to ask and get the
> name "WorkbenchPlugin" so I could remove it from the name?
Even in Eclipse 3.5 you where supposed to handle this situation
properly. The documentation of the product constant WINDOW_IMAGES says:
"The value is a comma-separated list of paths, where each path is either
a fully qualified valid URL or a path relative to the product's defining
bundle."
You probably need to bite the bullet. Note that "the product's defining
bundle" can be obtained from IProduct.getDefiningBundle().
You can check how Eclipse solves this by peeking into the internal
classes BrandingProperties and ProductProperties.
I just see that birt's browser uses the String pattern matching here:
url.split( ",\\s*" )
where "url" is the string returned from the product property.
HTH & Greetings from Bremen,
Daniel Krügler
|
|
|
Re: product.getProperty(IProductConstants.WINDOW_IMAGES) [message #644136 is a reply to message #642684] |
Thu, 09 December 2010 15:52 |
Carmelo Messages: 224 Registered: July 2009 |
Senior Member |
|
|
thx for your help
ciaoo
"Daniel Krügler" <dsp@bdal.de> ha scritto nel messaggio
news:id7t0r$jqf$1@news.eclipse.org...
> On 12/2/2010 10:34, Kar wrote:
>> Hi all,
>> I was using the previous call to get the information defined in the
>> product and use the images ...
>>
>> it was working in 3.5 galileo perfectly. Now in 3.6.1 the method returns
>> a sequence of names with starting with the name of the plugin
>>
>> 3.5
>> icons/icon-16.gif,icons/icon-32.gif,icons/icon-48.gif
>>
>> 3.6
>> /WorkbenchPlugin/icons/icon-16.gif, /WorkbenchPlugin/icons/icon-32.gif,
>> /WorkbenchPlugin/icons/icon-48.gif
>>
>>
>> from 3.6 and from the product object is there a way to ask and get the
>> name "WorkbenchPlugin" so I could remove it from the name?
>
> Even in Eclipse 3.5 you where supposed to handle this situation properly.
> The documentation of the product constant WINDOW_IMAGES says:
>
> "The value is a comma-separated list of paths, where each path is either a
> fully qualified valid URL or a path relative to the product's defining
> bundle."
>
> You probably need to bite the bullet. Note that "the product's defining
> bundle" can be obtained from IProduct.getDefiningBundle().
>
> You can check how Eclipse solves this by peeking into the internal classes
> BrandingProperties and ProductProperties.
>
> I just see that birt's browser uses the String pattern matching here:
>
> url.split( ",\\s*" )
>
> where "url" is the string returned from the product property.
>
> HTH & Greetings from Bremen,
>
> Daniel Krügler
>
>
|
|
|
Powered by
FUDForum. Page generated in 0.02750 seconds