diff --git a/dist/bundle.js b/dist/bundle.js index be2dbad9e..6d9d7f52d 100644 --- a/dist/bundle.js +++ b/dist/bundle.js @@ -82266,6 +82266,10 @@ BI.shortcut("bi.rich_editor_text_toolbar", BI.RichEditorTextToolbar);/** // return false; }, + focus: function () { + this.instance.focus(); + }, + setValue: function (v) { this.instance.setContent(v); }, @@ -82451,6 +82455,10 @@ BI.shortcut("bi.rich_editor_text_toolbar", BI.RichEditorTextToolbar);/** // return false; }, + focus: function () { + this.setFocus(this.elm.element[0]); + }, + blur: function () { this.isFocused = false; this.elm.element.removeClass(prefix + "selected"); @@ -83085,6 +83093,10 @@ BI.RichEditor = BI.inherit(BI.Widget, { }); }, + focus: function () { + this.editor.focus(); + }, + setValue: function (v) { this.editor.setValue(v); }, diff --git a/dist/case.js b/dist/case.js index c48c75ead..ebd066064 100644 --- a/dist/case.js +++ b/dist/case.js @@ -10324,6 +10324,10 @@ BI.shortcut("bi.rich_editor_text_toolbar", BI.RichEditorTextToolbar);/** // return false; }, + focus: function () { + this.instance.focus(); + }, + setValue: function (v) { this.instance.setContent(v); }, @@ -10509,6 +10513,10 @@ BI.shortcut("bi.rich_editor_text_toolbar", BI.RichEditorTextToolbar);/** // return false; }, + focus: function () { + this.setFocus(this.elm.element[0]); + }, + blur: function () { this.isFocused = false; this.elm.element.removeClass(prefix + "selected"); @@ -11143,6 +11151,10 @@ BI.RichEditor = BI.inherit(BI.Widget, { }); }, + focus: function () { + this.editor.focus(); + }, + setValue: function (v) { this.editor.setValue(v); }, diff --git a/dist/demo.js b/dist/demo.js index 5c030dbee..c7a2b3987 100644 --- a/dist/demo.js +++ b/dist/demo.js @@ -859,15 +859,26 @@ BI.shortcut("demo.multifile_editor", Demo.CodeEditor);Demo.RichEditor = BI.inher this.editor = BI.createWidget({ type: "bi.rich_editor", cls: "mvc-border", - width: 600, - height: 400 + width: "100%", + height: "100%" }); BI.createWidget({ type: "bi.vertical", element: this, hgap: 30, vgap: 50, - items: [this.editor] + items: [{ + type: "bi.absolute", + width: 600, + height: 400, + items: [{ + el: this.editor, + left: 10, + right: 10, + top: 10, + bottom: 10 + }] + }] }); }, @@ -877,6 +888,8 @@ BI.shortcut("demo.multifile_editor", Demo.CodeEditor);Demo.RichEditor = BI.inher var style = image.style; this.editor.setValue("