mirror of
https://github.com/atom/atom.git
synced 2026-01-22 21:38:10 -05:00
Clear cursor blink interval when editor component unmounts
This commit is contained in:
@@ -29,6 +29,9 @@ CursorsComponent = React.createClass
|
||||
@subscribe editor, 'cursors-moved', @pauseCursorBlinking
|
||||
@startBlinkingCursors()
|
||||
|
||||
componentWillUnmount: ->
|
||||
@stopBlinkingCursors()
|
||||
|
||||
startBlinkingCursors: ->
|
||||
@cursorBlinkIntervalHandle = setInterval(@toggleCursorBlink, @props.cursorBlinkPeriod / 2)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user