(doc, origin, prev, sel)
| 6626 | } |
| 6627 | |
| 6628 | function selectionEventCanBeMerged(doc, origin, prev, sel) { |
| 6629 | var ch = origin.charAt(0); |
| 6630 | return ch == "*" || |
| 6631 | ch == "+" && |
| 6632 | prev.ranges.length == sel.ranges.length && |
| 6633 | prev.somethingSelected() == sel.somethingSelected() && |
| 6634 | new Date - doc.history.lastSelTime <= (doc.cm ? doc.cm.options.historyEventDelay : 500); |
| 6635 | } |
| 6636 | |
| 6637 | // Called whenever the selection changes, sets the new selection as |
| 6638 | // the pending selection in the history, and pushes the old pending |
no outgoing calls
no test coverage detected