Eliminate another unnecessary call to highlightCursorLine

This commit is contained in:
Nathan Sobo
2012-11-01 14:43:43 -06:00
parent a0770c41db
commit 9cbcc9e7e3

View File

@@ -345,7 +345,6 @@ class Editor extends View
else
@gutter.addClass('drop-shadow')
@on 'cursor-move', ({bufferChanged}) => @highlightCursorLine() unless bufferChanged
@on 'selection-change', => @highlightCursorLine()
selectOnMousemoveUntilMouseup: ->
@@ -962,6 +961,7 @@ class Editor extends View
highlightCursorLine: ->
return if @mini
@highlightedLine?.removeClass('cursor-line')
if @getSelection().isSingleScreenLine()
@highlightedLine = @lineElementForScreenRow(@getCursorScreenRow())