浏览代码

Merge pull request #9 from ckeditor/t/6

Fix: The `DecoupledEditorUIView` should register `#toolbar` and `#editable` views as children. Closes #6.
Piotrek Koszuliński 7 年之前
父节点
当前提交
0d4998c807
共有 1 个文件被更改,包括 1 次插入12 次删除
  1. 1 12
      packages/ckeditor5-editor-decoupled/src/decouplededitoruiview.js

+ 1 - 12
packages/ckeditor5-editor-decoupled/src/decouplededitoruiview.js

@@ -55,16 +55,8 @@ export default class DecoupledEditorUIView extends EditorUIView {
 				class: 'ck-reset_all'
 			}
 		} );
-	}
-
-	/**
-	 * @inheritDoc
-	 */
-	render() {
-		super.render();
 
-		this.toolbar.render();
-		this.editable.render();
+		this.registerChildren( [ this.toolbar, this.editable ] );
 	}
 
 	/**
@@ -84,9 +76,6 @@ export default class DecoupledEditorUIView extends EditorUIView {
 		if ( removeEditable ) {
 			this.editable.element.remove();
 		}
-
-		this.toolbar.destroy();
-		this.editable.destroy();
 	}
 
 	/**