Extends
- goog.events.EventTarget
Methods
closed()
Callback when the view is hidden from the user.
This may include collapsing it, switching to another another view in a tabbed view container, etc.
editorChanged(editor)
Callback received when the focused editor was changed.
When the view renderer is installed, there might be no editor loaded.
However, if the editor is already loaded when install is called, this method is called immediately after install.
The view is not notified when the editor is disposed, but it can listen for the
sync.api.Editor.EventTypes.DISPOSE event.
Parameters:
Name | Type | Description |
---|---|---|
editor |
sync.api.Editor | The new editor. |
focus()
Method called to focus the current view.
getTitle() → {string}
Returns the title of the view.
Returns:
The title of the view.
- Type
- string
getTitleTooltip() → {string}
Returns the tooltip for the title of the view.
Returns:
The tooltip.
- Type
- string
install(element)
This method is called when the view renderer is linked to the actual
place where the view will be rendered.
Parameters:
Name | Type | Description |
---|---|---|
element |
HTMLElement | The element. |
opened()
Callback when the view is shown to the user.
This may include expading it, switching the tab of this view in a tabbed view container, etc.
supportsEditor(editor) → {boolean}
Method used to determine if a given editor is supported. If supported, sync.view.ViewRenderer#editorChanged
will be called for that editor.
By default, views support only Author editors.
Parameters:
Name | Type | Description |
---|---|---|
editor |
sync.api.Editor | The editor to check support for. |
Returns:
returns true if the given editor is supported.
- Type
- boolean