Add commonly used Editor methods to Editor View

Mini-editors use these methods very often, but really we shouldn't need to do
this.
This commit is contained in:
probablycorey 2014-01-10 16:38:36 -08:00
parent c19c8c5341
commit 5e674fe29e

View File

@ -220,6 +220,18 @@ class EditorView extends View
getEditor: ->
@editor
# {Delegates to: Editor.getText}
getText: ->
@editor.getText()
# {Delegates to: Editor.setText}
setText: (text) ->
@editor.setText(text)
# {Delegates to: Editor.insertText}
insertText: (text, options) ->
@editor.insertText(text, options)
# Private:
setHeightInLines: (heightInLines)->
heightInLines ?= @calculateHeightInLines()