Browse Source

Merge pull request #302 in FUI/fineui from ~WINDY/fui:master to master

* commit 'd8e8dbf5784834026ea46c4fa0d80d8c87b0317a':
  rich_editor可以指定是否只读
es6
guy 7 years ago
parent
commit
ac42318013
  1. 9
      dist/bundle.js
  2. 9
      dist/case.js
  3. 3
      src/case/richeditor/niceditor/niceditor.js
  4. 6
      src/case/richeditor/richeditor.js

9
dist/bundle.js vendored

@ -82239,6 +82239,9 @@ BI.shortcut("bi.rich_editor_text_toolbar", BI.RichEditorTextToolbar);/**
} else {
console.error("不支持此浏览器");
}
if(o.readOnly) {
newInstance.disable();
}
return newInstance;
},
@ -83048,7 +83051,8 @@ BI.RichEditor = BI.inherit(BI.Widget, {
this.editor = BI.createWidget({
type: "bi.nic_editor",
width: o.width,
height: o.height
height: o.height,
readOnly: o.readOnly
});
this.editor.on(BI.NicEditor.EVENT_BLUR, function () {
@ -83059,6 +83063,7 @@ BI.RichEditor = BI.inherit(BI.Widget, {
type: "bi.combo",
element: this,
toggle: false,
trigger: o.readOnly ? "" : "click",
direction: "top,left",
isNeedAdjustWidth: false,
isNeedAdjustHeight: false,
@ -83076,6 +83081,7 @@ BI.RichEditor = BI.inherit(BI.Widget, {
});
this.combo.on(BI.Combo.EVENT_AFTER_HIDEVIEW, function () {
self.fireEvent(BI.RichEditor.EVENT_AFTER_HIDEVIEW);
});
},
@ -83087,6 +83093,7 @@ BI.RichEditor = BI.inherit(BI.Widget, {
return this.editor.getValue();
}
});
BI.RichEditor.EVENT_AFTER_HIDEVIEW = "EVENT_AFTER_HIDEVIEW";
BI.RichEditor.EVENT_CONFIRM = "EVENT_CONFIRM";
BI.shortcut("bi.rich_editor", BI.RichEditor);/**
* 分段控件使用的button

9
dist/case.js vendored

@ -10297,6 +10297,9 @@ BI.shortcut("bi.rich_editor_text_toolbar", BI.RichEditorTextToolbar);/**
} else {
console.error("不支持此浏览器");
}
if(o.readOnly) {
newInstance.disable();
}
return newInstance;
},
@ -11106,7 +11109,8 @@ BI.RichEditor = BI.inherit(BI.Widget, {
this.editor = BI.createWidget({
type: "bi.nic_editor",
width: o.width,
height: o.height
height: o.height,
readOnly: o.readOnly
});
this.editor.on(BI.NicEditor.EVENT_BLUR, function () {
@ -11117,6 +11121,7 @@ BI.RichEditor = BI.inherit(BI.Widget, {
type: "bi.combo",
element: this,
toggle: false,
trigger: o.readOnly ? "" : "click",
direction: "top,left",
isNeedAdjustWidth: false,
isNeedAdjustHeight: false,
@ -11134,6 +11139,7 @@ BI.RichEditor = BI.inherit(BI.Widget, {
});
this.combo.on(BI.Combo.EVENT_AFTER_HIDEVIEW, function () {
self.fireEvent(BI.RichEditor.EVENT_AFTER_HIDEVIEW);
});
},
@ -11145,6 +11151,7 @@ BI.RichEditor = BI.inherit(BI.Widget, {
return this.editor.getValue();
}
});
BI.RichEditor.EVENT_AFTER_HIDEVIEW = "EVENT_AFTER_HIDEVIEW";
BI.RichEditor.EVENT_CONFIRM = "EVENT_CONFIRM";
BI.shortcut("bi.rich_editor", BI.RichEditor);/**
* 分段控件使用的button

3
src/case/richeditor/niceditor/niceditor.js

@ -38,6 +38,9 @@
} else {
console.error("不支持此浏览器");
}
if(o.readOnly) {
newInstance.disable();
}
return newInstance;
},

6
src/case/richeditor/richeditor.js

@ -18,7 +18,8 @@ BI.RichEditor = BI.inherit(BI.Widget, {
this.editor = BI.createWidget({
type: "bi.nic_editor",
width: o.width,
height: o.height
height: o.height,
readOnly: o.readOnly
});
this.editor.on(BI.NicEditor.EVENT_BLUR, function () {
@ -29,6 +30,7 @@ BI.RichEditor = BI.inherit(BI.Widget, {
type: "bi.combo",
element: this,
toggle: false,
trigger: o.readOnly ? "" : "click",
direction: "top,left",
isNeedAdjustWidth: false,
isNeedAdjustHeight: false,
@ -46,6 +48,7 @@ BI.RichEditor = BI.inherit(BI.Widget, {
});
this.combo.on(BI.Combo.EVENT_AFTER_HIDEVIEW, function () {
self.fireEvent(BI.RichEditor.EVENT_AFTER_HIDEVIEW);
});
},
@ -57,5 +60,6 @@ BI.RichEditor = BI.inherit(BI.Widget, {
return this.editor.getValue();
}
});
BI.RichEditor.EVENT_AFTER_HIDEVIEW = "EVENT_AFTER_HIDEVIEW";
BI.RichEditor.EVENT_CONFIRM = "EVENT_CONFIRM";
BI.shortcut("bi.rich_editor", BI.RichEditor);
Loading…
Cancel
Save