| 2908 | } |
| 2909 | |
| 2910 | function fireCallbacksForOps(group) { |
| 2911 | // Calls delayed callbacks and cursorActivity handlers until no |
| 2912 | // new ones appear |
| 2913 | var callbacks = group.delayedCallbacks, i = 0; |
| 2914 | do { |
| 2915 | for (; i < callbacks.length; i++) |
| 2916 | callbacks[i](); |
| 2917 | for (var j = 0; j < group.ops.length; j++) { |
| 2918 | var op = group.ops[j]; |
| 2919 | if (op.cursorActivityHandlers) |
| 2920 | while (op.cursorActivityCalled < op.cursorActivityHandlers.length) |
| 2921 | op.cursorActivityHandlers[op.cursorActivityCalled++](op.cm); |
| 2922 | } |
| 2923 | } while (i < callbacks.length); |
| 2924 | } |
| 2925 | |
| 2926 | // Finish an operation, updating the display and signalling delayed events |
| 2927 | function endOperation(cm) { |