BUGFIX Set Editor if getEditor() is null rather than onmatch

This commit is contained in:
Simon Welsh 2012-05-19 15:51:09 +12:00 committed by Ingo Schommer
parent 5b0734943f
commit 31db970fb2

View File

@ -354,7 +354,6 @@ ss.editorWrappers['default'] = ss.editorWrappers.tinyMCE;
var titleEl = this.find(':header:first');
this.getDialog().attr('title', titleEl.text());
this.setEditor(ss.editorWrappers['default']());
this._super();
this.redraw();
@ -378,6 +377,19 @@ ss.editorWrappers['default'] = ss.editorWrappers.tinyMCE;
updateFromEditor: function() {
this.getEditor().onopen();
window._ss_htmleditorfield_bookmark = this.getEditor().createBookmark();
},
createEditor: function(){
return ss.editorWrappers['default']();
},
/**
* Get the tinyMCE editor
*/
getEditor: function(){
var val = this._super();
if(!val) {
this.setEditor(val = this.createEditor());
}
return val;
}
});