public void EndEdit() { recoveryIntervals.Push( new RecoveryInterval { Start = currentRecoveryStart, Count = currentRecoveryCount, }); }
public void BeginEdit() { currentStage = 1; // Save front to history before editing if (history != null) { Debug.Assert(Count != 0); history.Push(null); // sentinel int count = this.Count; for (int i = 0; i != count; ++i) { history.Push(front[i]); } } }
public void Pop(int count) { int newCount = Count - count; while (currentRecoveryStart > newCount) { --currentRecoveryStart; ++currentRecoveryCount; savedTags.Push(tags[currentRecoveryStart]); savedData.Push(data[currentRecoveryStart]); } InternalPop(count); }