From 6610d05549e347fbb548e606fa66cfb113df9e67 Mon Sep 17 00:00:00 2001 From: qsm-odoo Date: Wed, 24 Feb 2016 13:13:12 +0100 Subject: [REF] web_editor,website,mass_mailing: JS/XML update * Adapt DOM selectors * Refactore dialog XMLs to have odoo styling * New editor options (background-position, ...) * Various improvements --- addons/web_editor/static/src/js/inline.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'addons/web_editor/static/src/js/inline.js') diff --git a/addons/web_editor/static/src/js/inline.js b/addons/web_editor/static/src/js/inline.js index 2b6ee1c6595..8f63d603b20 100644 --- a/addons/web_editor/static/src/js/inline.js +++ b/addons/web_editor/static/src/js/inline.js @@ -57,10 +57,10 @@ snippet_editor.Class.include({ transcoder.class_to_style($editable); // fix outlook image rendering bug - _.each(['width', 'height'], function(attribute) { - $editable.find('img[style*="width"], img[style*="height"]').attr(attribute, function(){ + _.each(['width', 'height'], function (attribute) { + $editable.find('img[style*="width"], img[style*="height"]').attr(attribute, function () { return $(this)[attribute](); - }).css(attribute, function(){ + }).css(attribute, function () { return $(this).get(0).style[attribute] || 'auto'; }); }); -- cgit v1.2.3