|
|
Re: How can I provide variables for property tests to create dynamic help content [message #730858 is a reply to message #730670] |
Thu, 29 September 2011 11:54 |
Riccardo Missing name Messages: 9 Registered: September 2011 |
Junior Member |
|
|
The evaluation context seems to be created in org.eclipse.help.UAContentFilter whereby the platform variable is added via context.addVariable(VARIABLE_PLATFORM, Platform.class). It would be nice to have an extension point which allows to add additional variables to that context.
Since I implement my own providers for tocs and content extensions as well as content producers (see my other post "message #730008"), I have to implement most of the other interfaces (eg. IToc, ITopic, ...) to. This interfaces extend IUAElement which defines the method isEnabled(IEvaluationContext context). In my case it would be better if these method would be defined without the context as a paramter. In this way the implementing class could determine the enabled state by here own rules. In the case of the class org.eclipse.help.internal.UAElement you can use an IEvaluationContext, which is provide by the internals of the org.eclipse.help bundle.
What do you think about that proposal Chris? Would it lead to a better design? At least in my case the context is useless, because I can not define tests for my dynamic created elements in the plugin.xml and the enabled state is determined by other properties.
[Updated on: Thu, 29 September 2011 12:02] Report message to a moderator
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.05710 seconds