From 459b15ac93e2355d1a4b0393f12bac35941962dc Mon Sep 17 00:00:00 2001 From: Nathan Gray Date: Tue, 10 Feb 2015 19:34:46 +0000 Subject: [PATCH] Fully clear existing ActionObject before re-using it. Fixes context menu missing after close & re-open home tab. --- etemplate/js/et2_core_DOMWidget.js | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/etemplate/js/et2_core_DOMWidget.js b/etemplate/js/et2_core_DOMWidget.js index edf05ff40c..c04235c510 100644 --- a/etemplate/js/et2_core_DOMWidget.js +++ b/etemplate/js/et2_core_DOMWidget.js @@ -527,9 +527,14 @@ var et2_DOMWidget = et2_widget.extend(et2_IDOMNode, objectManager.manager.getActionById(this.id) || objectManager.manager )); } + else + { + widget_object.setAOI(new et2_action_object_impl(this, this.getDOMNode())); + } // Delete all old objects widget_object.clear(); + widget_object.unregisterActions(); // Go over the widget & add links - this is where we decide which actions are // 'allowed' for this widget at this time