angieBabel / blockly

Automatically exported from code.google.com/p/blockly
0 stars 0 forks source link

Make the realtime synchronization be more atomic #195

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
See https://developers.google.com/drive/realtime/advanced-model#atomicity for 
more background.

I think that basically want to make sure that everything done between mouse 
down and mouse up is done with a Model.beginCompoundOperation() / 
model.endCompoundOperation() pair.

Original issue reported on code.google.com by ma...@google.com on 23 Jan 2014 at 6:58

GoogleCodeExporter commented 8 years ago
We can't really what we want because the Model.beginCompoundOperation() / 
model.endCompoundOperation() pair "MUST start and end in the same synchronous 
execution block".  We can, however, at least make sure that everything within a 
mouseUp handler becomes atomic.  

We can also handle the atomicity of undo/redo by explicitly modeling the undo 
stack by our code by creating our own synthetic realtime operation for 
beginning and ending "command"s.  That work will be done as part of issue 192.

Original comment by ma...@google.com on 14 Feb 2014 at 7:12