mirror of
https://github.com/atom/atom.git
synced 2026-01-23 05:48:10 -05:00
Update telepath
This commit is contained in:
@@ -39,13 +39,13 @@ module.exports =
|
||||
event.id = nextOutputEventId++
|
||||
console.log 'sending event', event.id, event
|
||||
connection.send(event)
|
||||
doc.on('replicate-change', outputListener)
|
||||
doc.on('replicate-patch', outputListener)
|
||||
|
||||
queuedEvents = []
|
||||
nextInputEventId = 1
|
||||
handleInputEvent = (event) ->
|
||||
console.log 'received event', event.id, event
|
||||
doc.applyRemoteChange(event)
|
||||
doc.applyPatch(event)
|
||||
nextInputEventId = event.id + 1
|
||||
flushQueuedEvents = ->
|
||||
loop
|
||||
@@ -66,7 +66,7 @@ module.exports =
|
||||
queuedEvents.push(event)
|
||||
|
||||
connection.on 'close', ->
|
||||
doc.off('replicate-change', outputListener)
|
||||
doc.off('replicate-patch', outputListener)
|
||||
|
||||
connection.on 'error', (error) ->
|
||||
console.error 'connection error', error.stack ? error
|
||||
|
||||
@@ -163,7 +163,7 @@ class Session
|
||||
event.site = window.site.id
|
||||
|
||||
connectDocument: ->
|
||||
@doc.on 'replicate-change', (event) =>
|
||||
@doc.on 'replicate-patch', (event) =>
|
||||
@stampEvent(event)
|
||||
console.log "sending replication event", event
|
||||
@channel.broadcast('document-changed', event)
|
||||
@@ -171,7 +171,7 @@ class Session
|
||||
@channel.on 'document-changed', (event) =>
|
||||
console.log "receiving replication event", event
|
||||
@verifyEvent(event)
|
||||
@doc.applyRemoteChange(event)
|
||||
@doc.applyPatch(event)
|
||||
|
||||
snapshotRepository: (callback) ->
|
||||
patrick.snapshot project.getPath(), (error, repoSnapshot) =>
|
||||
|
||||
2
vendor/telepath
vendored
2
vendor/telepath
vendored
Submodule vendor/telepath updated: 1ffdbdb51f...473df67fec
Reference in New Issue
Block a user