private void OnUndo(object sender, TaskEventArgs <object> e) { if (this.Recorder != null) { RecorderTaskEventArgs args = new RecorderTaskEventArgs(this); this.Recorder.Undoing(args); if (args.Enabled) { this.unExecute((object)null); } this.Recorder.Undone(args); } else { this.unExecute((object)null); } }
private void OnExecute(object sender, TaskEventArgs <object> e) { if (e.TaskMode != TaskMode.Redo) { return; } if (this.Recorder != null) { RecorderTaskEventArgs args = new RecorderTaskEventArgs(this); this.Recorder.Redoing(args); if (args.Enabled) { this.execute((object)null); } this.Recorder.Redone(args); } else { this.execute((object)null); } }