(cm)
| 2881 | var nextOpId = 0; |
| 2882 | // Start a new operation. |
| 2883 | function startOperation(cm) { |
| 2884 | cm.curOp = { |
| 2885 | cm: cm, |
| 2886 | viewChanged: false, // Flag that indicates that lines might need to be redrawn |
| 2887 | startHeight: cm.doc.height, // Used to detect need to update scrollbar |
| 2888 | forceUpdate: false, // Used to force a redraw |
| 2889 | updateInput: null, // Whether to reset the input textarea |
| 2890 | typing: false, // Whether this reset should be careful to leave existing text (for compositing) |
| 2891 | changeObjs: null, // Accumulated changes, for firing change events |
| 2892 | cursorActivityHandlers: null, // Set of handlers to fire cursorActivity on |
| 2893 | cursorActivityCalled: 0, // Tracks which cursorActivity handlers have been called already |
| 2894 | selectionChanged: false, // Whether the selection needs to be redrawn |
| 2895 | updateMaxLine: false, // Set when the widest line needs to be determined anew |
| 2896 | scrollLeft: null, scrollTop: null, // Intermediate scroll position, not pushed to DOM yet |
| 2897 | scrollToPos: null, // Used to scroll to a specific position |
| 2898 | id: ++nextOpId // Unique ID |
| 2899 | }; |
| 2900 | if (operationGroup) { |
| 2901 | operationGroup.ops.push(cm.curOp); |
| 2902 | } else { |
| 2903 | cm.curOp.ownsGroup = operationGroup = { |
| 2904 | ops: [cm.curOp], |
| 2905 | delayedCallbacks: [] |
| 2906 | }; |
| 2907 | } |
| 2908 | } |
| 2909 | |
| 2910 | function fireCallbacksForOps(group) { |
| 2911 | // Calls delayed callbacks and cursorActivity handlers until no |
no outgoing calls
no test coverage detected