X-Git-Url: http://git.roojs.org/?a=blobdiff_plain;f=roojs-bootstrap-debug.js;h=2f4eecb581d49591d0e2991a3bef89f9cc361ff1;hb=c2cce7fd72c03eaee5d7451b4e5484611ee41f4b;hp=bec7325023ea07e0774692414a6c24a23a01dfd2;hpb=8c11b1b1927839502a3018b0a95cf83c29244d24;p=roojs1 diff --git a/roojs-bootstrap-debug.js b/roojs-bootstrap-debug.js index bec7325023..2f4eecb581 100644 --- a/roojs-bootstrap-debug.js +++ b/roojs-bootstrap-debug.js @@ -29497,7 +29497,7 @@ Roo.extend(Roo.HtmlEditorCore, Roo.Component, { .map(function(g) { return g.toDataURL(); }) .filter(function(g) { return g != 'about:blank'; }); - Roo.log(html); + //Roo.log(html); html = this.cleanWordChars(html); var d = (new DOMParser().parseFromString(html, 'text/html')).body; @@ -29515,13 +29515,17 @@ Roo.extend(Roo.HtmlEditorCore, Roo.Component, { return false; } + + if (images.length > 0) { - // if they mix thse, then it's going to be messy... - var imgs = Array.from(d.getElementsByTagName('img')); - imgs.concat(Array.from(document.getElementsByTagName('v:imagedata'))); // not sure if we need array from here. + // replace all v:imagedata - with img. + Roo.each(document.getElementsByTagName('v:imagedata'), function(node) { + node.parentNode.insertBefore(node, d.createElement('img')); + node.parentNode.removeChild(node); + }); - Roo.each(imgs, function(img, i) { + Roo.each(imgs, function(d.getElementsByTagName('img'), i) { img.setAttribute('src', images[i]); }); }