From 9c0f1d428ff91b28edbce1635cfcfec989e6d2ee Mon Sep 17 00:00:00 2001 From: Corey Johnson & Nathan Sobo Date: Tue, 13 Nov 2012 11:21:46 -0800 Subject: [PATCH] Rename updateAppearance to updateDisplay --- spec/app/editor-spec.coffee | 2 +- src/app/cursor-view.coffee | 6 +++--- src/app/editor.coffee | 4 ++-- src/app/selection-view.coffee | 6 +++--- 4 files changed, 9 insertions(+), 9 deletions(-) diff --git a/spec/app/editor-spec.coffee b/spec/app/editor-spec.coffee index baeceff6f..ef42aa73b 100644 --- a/spec/app/editor-spec.coffee +++ b/spec/app/editor-spec.coffee @@ -863,7 +863,7 @@ describe "Editor", -> expect(selectionView.regions.length).toBe 3 expect(selectionView.find('.selection').length).toBe 3 - selectionView.updateAppearance() + selectionView.updateDisplay() expect(selectionView.regions.length).toBe 3 expect(selectionView.find('.selection').length).toBe 3 diff --git a/src/app/cursor-view.coffee b/src/app/cursor-view.coffee index f4fad1c62..53106597e 100644 --- a/src/app/cursor-view.coffee +++ b/src/app/cursor-view.coffee @@ -14,7 +14,7 @@ class CursorView extends View initialize: (@cursor, @editor) -> @cursor.on 'change-screen-position.cursor-view', (screenPosition, { bufferChange, autoscroll }) => - @updateAppearance({autoscroll}) + @updateDisplay({autoscroll}) @removeIdleClassTemporarily() unless bufferChange @trigger 'cursor-move', {bufferChange} @@ -23,7 +23,7 @@ class CursorView extends View afterAttach: (onDom) -> return unless onDom - @updateAppearance() + @updateDisplay() @editor.syncCursorAnimations() remove: -> @@ -31,7 +31,7 @@ class CursorView extends View @cursor.off('.cursor-view') super - updateAppearance: (options={}) -> + updateDisplay: (options={}) -> autoscroll = options.autoscroll ? true screenPosition = @getScreenPosition() pixelPosition = @getPixelPosition() diff --git a/src/app/editor.coffee b/src/app/editor.coffee index bf40bfdfa..335e88c9e 100644 --- a/src/app/editor.coffee +++ b/src/app/editor.coffee @@ -673,11 +673,11 @@ class Editor extends View updateCursorViews: -> for cursorView in @getCursorViews() - cursorView.updateAppearance() + cursorView.updateDisplay() updateSelectionViews: -> for selectionView in @getSelectionViews() - selectionView.updateAppearance() + selectionView.updateDisplay() syncCursorAnimations: -> for cursorView in @getCursorViews() diff --git a/src/app/selection-view.coffee b/src/app/selection-view.coffee index 889fcf34c..9583f9d8c 100644 --- a/src/app/selection-view.coffee +++ b/src/app/selection-view.coffee @@ -12,11 +12,11 @@ class SelectionView extends View initialize: ({@editor, @selection} = {}) -> @regions = [] - @selection.on 'change-screen-range', => @updateAppearance() + @selection.on 'change-screen-range', => @updateDisplay() @selection.on 'destroy', => @remove() - @updateAppearance() + @updateDisplay() - updateAppearance: -> + updateDisplay: -> @clearRegions() range = @getScreenRange()