From: Alan Date: Fri, 17 Feb 2023 04:52:06 +0000 (+0800) Subject: Roo/bootstrap/form/HtmlEditorToolbar/Standard.js X-Git-Url: http://git.roojs.org/?p=roojs1;a=commitdiff_plain;h=5bad71e7a4ede882de43dff7e429c30dac0bacf1 Roo/bootstrap/form/HtmlEditorToolbar/Standard.js --- diff --git a/Roo/bootstrap/form/HtmlEditorToolbar/Standard.js b/Roo/bootstrap/form/HtmlEditorToolbar/Standard.js index e7732f725d..44c2de767c 100644 --- a/Roo/bootstrap/form/HtmlEditorToolbar/Standard.js +++ b/Roo/bootstrap/form/HtmlEditorToolbar/Standard.js @@ -249,7 +249,8 @@ Roo.extend(Roo.bootstrap.form.HtmlEditorToolbar.Standard, Roo.bootstrap.nav.Simp bl.image_src = reader.result; //bl.caption = f.name; bl.updateElement(sn); - editor.owner.fireEvent('editorevent', editor, false); + editor.owner.fireEvent('editorevent', editor.owner, false); + editor.owner.fireEvent('imageupdate', editor.owner, false); // we only do the first file!! and replace. return; } @@ -260,13 +261,15 @@ Roo.extend(Roo.bootstrap.form.HtmlEditorToolbar.Standard, Roo.bootstrap.nav.Simp caption_display : 'none' //default to hide captions.. }); editor.insertAtCursor(fig.toHTML()); - editor.owner.fireEvent('editorevent', editor, false); + editor.owner.fireEvent('editorevent', editor.owner, false); + editor.owner.fireEvent('imageadd', editor.owner, false); return; } // just a standard img.. if (sn && sn.tagName.toUpperCase() == 'IMG') { sn.src = reader.result; - editor.owner.fireEvent('editorevent', editor, false); + editor.owner.fireEvent('editorevent', editor.owner, false); + editor.owner.fireEvent('imageupdate', editor.owner, false); return; } editor.insertAtCursor('');