(spans)
| 6729 | // When un/re-doing restores text containing marked spans, those |
| 6730 | // that have been explicitly cleared should not be restored. |
| 6731 | function removeClearedSpans(spans) { |
| 6732 | if (!spans) return null; |
| 6733 | for (var i = 0, out; i < spans.length; ++i) { |
| 6734 | if (spans[i].marker.explicitlyCleared) { if (!out) out = spans.slice(0, i); } |
| 6735 | else if (out) out.push(spans[i]); |
| 6736 | } |
| 6737 | return !out ? spans : out.length ? out : null; |
| 6738 | } |
| 6739 | |
| 6740 | // Retrieve and filter the old marked spans stored in a change event. |
| 6741 | function getOldSpans(doc, change) { |
no outgoing calls
no test coverage detected
searching dependent graphs…