Remove redundant update requests in editor view

This commit is contained in:
Nathan Sobo
2015-02-18 13:29:25 -07:00
parent 0d109d69f0
commit 1e8b0acbd0

View File

@@ -541,20 +541,17 @@ TextEditorComponent = React.createClass
if editor.selectionIntersectsVisibleRowRange(selection)
@selectionChanged = true
@requestUpdate()
onSelectionChanged: (selection) ->
{editor} = @props
if editor.selectionIntersectsVisibleRowRange(selection)
@selectionChanged = true
@requestUpdate()
onCursorAdded: (cursor) ->
@disposables.add cursor.onDidChangePosition @onCursorMoved
onCursorMoved: ->
@cursorMoved = true
@requestUpdate()
handleDragUntilMouseUp: (event, dragHandler) ->
{editor} = @props