syntax editor + minibar: fix bug with repeated switching back and forth

By avoiding "this" in callback functions, the code can be kept cleaner.
This commit is contained in:
hallgren
2012-11-23 13:15:16 +00:00
parent ee2f0a7487
commit 9e430184ba
3 changed files with 6 additions and 7 deletions

View File

@@ -103,8 +103,7 @@ Translations.prototype.show_translations=function(translationResults) {
var tbody=empty("tbody");
if(options.show_abstract && t.tree) {
function abs_act() {
var minibar = self.minibar;
bind(self.options.abstract_action,minibar)(t.tree)
self.options.abstract_action(t.tree)
}
var abs_hdr = options.abstract_action
? button("Abstract",abs_act)