From 3fd74146c2ca182fdb9ee880947e9996af74a2e7 Mon Sep 17 00:00:00 2001 From: qsm-odoo Date: Tue, 6 Dec 2016 17:16:00 +0100 Subject: [PATCH] [FIX] web_editor: let whole backend know when leaving fullscreen editor An enterprise feature was in conflict with the fullscreen mode of the editor (see commit https://github.com/odoo/enterprise/commit/125414b73e4d839fc44c445bb83591e84f4c855d which fixes it). This commit forces this feature to be retriggered when the fullscreen mode is left (as the feature is now put asleep during the fullscreen mode). This should obviously be improved to handle fullscreen mode with a more robust way. --- addons/web_editor/static/src/js/backend.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/web_editor/static/src/js/backend.js b/addons/web_editor/static/src/js/backend.js index 17ce8c3c1a1..36cd33c60fd 100644 --- a/addons/web_editor/static/src/js/backend.js +++ b/addons/web_editor/static/src/js/backend.js @@ -337,7 +337,7 @@ var FieldTextHtml = widget.extend({ $("body").toggleClass("o_form_FieldTextHtml_fullscreen"); var full = $("body").hasClass("o_form_FieldTextHtml_fullscreen"); self.$iframe.parents().toggleClass('o_form_fullscreen_ancestor', full); - self.resize(); + $(window).trigger("resize"); // induce a resize() call and let other backend elements know (the navbar extra items management relies on this) }); this.$body.on('click', '[data-action="cancel"]', function (event) {