if (this.enableBlocks) {
- Roo.htmleditor.Block.initAll(bd);
+ Array.from(bd.getElementsByTagName('img')).forEach(function(img) {
+ if (img.closest('figure')) { // assume!! that it's aready
+ return;
+ }
+ var fig = new Roo.htmleditor.BlockFigure({
+ image_src : img.src
+ });
+ fig.updateElement(img); // replace it..
+
+ });
new Roo.htmleditor.FilterBlock({ node : div });
}