mirror of
https://github.com/atom/atom.git
synced 2026-01-23 13:58:08 -05:00
Compare site id using site from original event
Previously the site was being looked for in a copy of the event where only the range and text keys were picked and so it was always missing.
This commit is contained in:
@@ -73,14 +73,13 @@ class TextBuffer
|
||||
### Internal ###
|
||||
|
||||
handleTextChange: (event) =>
|
||||
event = _.pick(event, 'oldRange', 'newRange', 'oldText', 'newText')
|
||||
@cachedMemoryContents = null
|
||||
@conflict = false if @conflict and !@isModified()
|
||||
marker.handleBufferChange(event) for marker in @getMarkers()
|
||||
@trigger 'changed', event
|
||||
bufferChangeEvent = _.pick(event, 'oldRange', 'newRange', 'oldText', 'newText')
|
||||
marker.handleBufferChange(bufferChangeEvent) for marker in @getMarkers()
|
||||
@trigger 'changed', bufferChangeEvent
|
||||
@scheduleModifiedEvents()
|
||||
if @state.site.id isnt event.site
|
||||
@trigger 'markers-updated'
|
||||
@trigger 'markers-updated' if @state.site.id isnt event.site
|
||||
|
||||
destroy: ->
|
||||
unless @destroyed
|
||||
|
||||
Reference in New Issue
Block a user