private UndoPropertyModification[] ProcessAutoKey(UndoPropertyModification[] modifications)
 {
     this.BeginKeyModification();
     AnimationWindowControl.RecordingState recordingState = new AnimationWindowControl.RecordingState(this.state, AnimationWindowControl.RecordingStateMode.AutoKey);
     UndoPropertyModification[]            result         = AnimationRecording.Process(recordingState, modifications);
     this.EndKeyModification();
     return(result);
 }
 public void AddKey(PropertyModification[] modifications)
 {
     UndoPropertyModification[] array = new UndoPropertyModification[modifications.Length];
     for (int i = 0; i < modifications.Length; i++)
     {
         PropertyModification propertyModification = modifications[i];
         array[i].previousValue = propertyModification;
         array[i].currentValue  = propertyModification;
     }
     this.BeginKeyModification();
     AnimationWindowControl.RecordingState recordingState = new AnimationWindowControl.RecordingState(this.state, AnimationWindowControl.RecordingStateMode.ManualKey);
     AnimationRecording.Process(recordingState, array);
     this.EndKeyModification();
     this.RemoveFromCandidates(modifications);
     this.ResampleAnimation();
     this.state.Repaint();
 }