Community
Participate
Working Groups
Similiar to https://bugs.eclipse.org/bugs/show_bug.cgi?id=369884 I think it would more much more consistent if the org.eclipse.e4.workbench.model would use the platform:/plugin/ prefix which for example are used for CSS resources or Icons. Currenty: <plugin> <extension id="id1" point="org.eclipse.e4.workbench.model"> <fragment uri="fragment.e4xmi"> </fragment> </extension> </plugin>
For reading an extension attribute that points to a resource, depending on what it is we need to support 2 or 3 methods: 1) relative to the plugin root: xmi/myFragment.e4xmi 2) Same as #1 with NL (optional): $nl$/xmi/myFragment.e4xmi 3) platform:/plugin URL PW
I think the methods 1) and 3) are useful and possible with some simple code changes in the ModelAssembler class. But why should I load different fragment.e4xmi elements based on the locale? Correct me if I'm wrong, but as far as I can remember is the translation of all displayed elements automatically done with the externalization mechanism. If somebody really has the special case to provide different Model-Elements based on the locale I think he is better off using a processor to add them dynamically.
Rene, maybe a different model fragment should be loaded based on the local setting? But I think if that is a requirements from Paul, we should open a new bug for 2.). Rene, if you interested in fixing that (I hoped so, therefore I copied you in the bug), can you please provide a Gerrit review to handle 1.) and 3.) Paul, if 2.) is a valid requirement, can you please open a new bug for this? My original bug was to have consistency in the URI handling.
I've provided a fix under: https://git.eclipse.org/r/17470 As Lars suggested it's just the implementation of method 1) and 3). But I think there should be a follow-up Bug for updating the PDE Schema-Editor, because the "uri" attribute is now a resource to which the PDE Schema-Editor can navigate. This navigation only works with the relative paths not with the new Platform-URIs.
*** Bug 376151 has been marked as a duplicate of this bug. ***
(In reply to Lars Vogel from comment #3) > Paul, if 2.) is a valid requirement, can you please open a new bug for this? > My original bug was to have consistency in the URI handling. My thinking on that was to have the same logic that we support in our many icon attributes, but arguably a uri attribute is not the same in this kind of extension point as text or an icon would be. I think it's fine to ignore that for now, and we could react to it if someone raises a bug about it with a more compelling usecase than "icon" works that way. PW
I think there is a difference between Icon handling and application-model fragment. An Icon is a piece of static that which content can not be translated but sometimes needs to be translated (=Icon which contains text). The application-model instead is an additional static configuration which enriches an existing model and its content will be parsed and the elements which needs to be translated can be translated on demand.
Released as http://git.eclipse.org/c/platform/eclipse.platform.ui.git/commit/?id=f368d17aa5f8ac1eac7c910c3ce34dd30b589f1f Thanks René PW
Verified in the build: I20131028-2000