PreviousNextTracker indexSee it online !

(21/314) 1441138 - Templates plugin creates spurious Action objects

In order to run template instances from macros, the
Templates plugin creates an Action instance for each
template. These Action instances are created while
setting up the plugin's menu items, and are bundled
into ActionSet objects with each submenu in the
Templates plugin menu hierarchy having its own ActionSet.

When the "Refresh Templates" item is selected from the
Templates menu, these Action objects get re-created.
Unfortunately, the old ActionSets are not being
removed. As a result, the user sees items labelled "<no
label set; plugin bug>" in the drop-down list under
Utilities->Global Options->Shortcuts. Each time the
"Refresh Templates" item is selected, the list of such
items grows.

The menu/Action creation process needs to be modified
to ensure that old template Action objects are removed
before the new ones are created.

Submitted sjakob - 2006-03-01 - 18:04:14z Assigned sjakob
Priority 5 Category None
Status Open Group None
Resolution None Visibility No


2006-10-12 - 15:41:32z
Logged In: YES

By passing a String to the ActionSet constructor (SVN commit
#7502) I was able to give the Templates ActionSets proper
labels, rather than "<no label set; plugin bug>".

Two problems remain, though:

1) The old ActionSets need to be removed when the template
list is refreshed.

2) The Templates ActionSets don't show up in the Shortcuts
pane following jEdit startup. After selecting "Refresh
Templates" they do show up, and each subsequent refresh adds
a new set of ActionSets.
2007-03-06 - 22:17:31z
Logged In: YES
Originator: NO

Is this still an issue with Templates Plugin 4.0.0?

After some refreshes I can't see any items labelled "<no label set; plugin bug>".

jEdit 4.3pre9
SUN JRE 1.5.0_11
2007-03-19 - 18:26:16z
Logged In: YES
Originator: YES

To rschwenn:

I would suggest you go back and re-read the comments history for this tracker item, specifically my comments of 2006-10-12.
2007-03-19 - 20:58:44z
Logged In: YES
Originator: NO

To sjacob:

Ok, i realized: You're one of the authors (sorry ), and so I guess now that Your mentioned "SVN commit #7502" is version 4.0.

I want to take back my last question :-) and only say:
Directly after jEdit start there are exactly 8 actions visible in the shortcuts pane. This does NOT change after one or more "Refresh Templates" for me. The actions are:

templates-tree : Templates Tree
templates-tree-float : Templates Tree (New Floating Instance)
templates-tree-toggle : Toggle Templates Tree
Templates.browse-templates : Browse Templates
Templates.edit-template : Edit template
Templates.expand-accelerator : Expand Accelerator
Templates.refresh-templates : Refresh templates : Save template