Explorar el Código

The `getEditableElement()` method was moved to base class.

Krzysztof Krztoń hace 7 años
padre
commit
112035b370
Se han modificado 1 ficheros con 2 adiciones y 7 borrados
  1. 2 7
      packages/ckeditor5-editor-classic/src/classiceditorui.js

+ 2 - 7
packages/ckeditor5-editor-classic/src/classiceditorui.js

@@ -69,13 +69,6 @@ export default class ClassicEditorUI extends EditorUI {
 		return this.view.element;
 		return this.view.element;
 	}
 	}
 
 
-	/**
-	 * @inheritDoc
-	 */
-	getEditableElement( rootName = 'main' ) {
-		return this.view.editable.name === rootName ? this.view.editable.element : null;
-	}
-
 	/**
 	/**
 	 * Initializes the UI.
 	 * Initializes the UI.
 	 *
 	 *
@@ -101,6 +94,8 @@ export default class ClassicEditorUI extends EditorUI {
 		view.editable.bind( 'isFocused' ).to( editor.editing.view.document );
 		view.editable.bind( 'isFocused' ).to( editor.editing.view.document );
 		view.editable.name = editingRoot.rootName;
 		view.editable.name = editingRoot.rootName;
 
 
+		this._editableElements.push( view.editable );
+
 		this.focusTracker.add( view.editable.editableElement );
 		this.focusTracker.add( view.editable.editableElement );
 
 
 		view.toolbar.fillFromConfig( this._toolbarConfig.items, this.componentFactory );
 		view.toolbar.fillFromConfig( this._toolbarConfig.items, this.componentFactory );