From 04730c83febc05979d10ef7e75cbe56953ae76d8 Mon Sep 17 00:00:00 2001 From: Hadi Nategh Date: Tue, 13 Jan 2015 15:51:30 +0000 Subject: [PATCH] Fix toolbar toggle buttons with Function are not getting executed --- etemplate/js/et2_widget_toolbar.js | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/etemplate/js/et2_widget_toolbar.js b/etemplate/js/et2_widget_toolbar.js index a3875cf437..38b3d394ac 100644 --- a/etemplate/js/et2_widget_toolbar.js +++ b/etemplate/js/et2_widget_toolbar.js @@ -440,13 +440,13 @@ var et2_toolbar = et2_DOMWidget.extend([et2_IInput], var click = function(e) { var action = this._actionManager.getActionById(e.data); - if (action && action.checkbox) - { - action.set_checked(!action.checked); - jQuery(button).toggleClass('toolbar_toggled'); - } - else if(action) + if(action) { + if (action.checkbox) + { + action.set_checked(!action.checked); + jQuery(button).toggleClass('toolbar_toggled'); + } this.value = action.id; action.data.event = e; action.execute([]);