Frank Schoenheit, Sun Microsystems Germany wrote:

> Hi Paolo,
> 
>> Why not the %origin% placeholder?
>> I just noticed that the graphic provider can handle demacrofyed urls 
>> like this one:
>> vnd.sun.star.expand:$UNO_USER_PACKAGES_CACHE/uno_packages/sJYsUf_/MyExtension.oxt/icons/lightbulb.jpg
> 
> because you would need to know, at time of creation of your extension,
> the "sJYsUf_" part of the path, which is impossible. Okay, with the
> brand-new XDeploymentHook interface, you could probably add a hook which
> is executed when the extension is deployed, and updates the
> configuration with the proper URL. Possible, but still pretty ugly, and
> a workaround, not a solution.

Sure? IIRC there was a way to have "%origin%" as a placeholder in
entries of xcu files that will be expanded at deployment time or can be
resolved at runtime to give you that path. I used that technique in
several extensions, without being forced to any such hacks as deployment
hooks.

A quick search showed me that this technique is still used, e.g. in the
presentation minimizer extension. The code in this extension using the
images referencing "%origin%" should show you whether the expansion
happens at runtime or already at deployment time (IIRC it was the latter).

Regards,
Mathias



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to