Plugin works but there is one problem with it. I've added two popup menu
actions to Templates View but I had to use Java reflection to get references
to template store (for import command) and tree viewer (for getting selected
because I could not find any better way to obtain reference to Java
Template store and items currently seleted in the view.
This could be easily fixed (probably without breaking and API in any
way) by making getTemplateStore() and getSelectedTemplates() methods
from class AbstractTemplatesPage public, and the part of
AbstractTemplatesPage contract. The first is now protected, the second
is private which makes it very hard to extend this view in portable way.
The question is: is there a better way to obtain TemplateStore and list
of selected items from templates page?
Piotr Maj wrote:
> I'm woking on plugin which makes it easy to share code templates via
> public templates repository. To make long story short please take a look
> at 1.5 minute screencast demonstrating what I mean:
> Update site for 3.5.0+: http://jcake.com/petr
> The question is: is there a better way to obtain TemplateStore and list
> of selected items from templates page?
I suggest you file an enhancement request against JDT Text and if
possible attach a patch.
Piotr Maj Messages: 19 Registered: July 2009 Location: Warsaw, Poland
On 2009-11-30, Daniel Megert <email@example.com> wrote:
>> The question is: is there a better way to obtain TemplateStore and list
>> of selected items from templates page?
> I suggest you file an enhancement request against JDT Text and if
> possible attach a patch.