Breyta

Deila með


UndoEngine.UndoUnit Class

Definition

Encapsulates a unit of work that a user can undo.

protected: ref class UndoEngine::UndoUnit
protected class UndoEngine.UndoUnit
Protected Class UndoEngine.UndoUnit
Inheritance
UndoEngine.UndoUnit

Remarks

The UndoEngine.UndoUnit class is a nested class within UndoEngine that encapsulates an action that a user can undo. The default UndoEngine.UndoUnit implementation monitors change notifications and builds up a list of events for each change. It saves these events using IDesignerSerializationService. An UndoEngine.UndoUnit receives event notifications for changes directly from UndoEngine through several public virtual methods. You can derive from UndoEngine.UndoUnit and perform any additional logic. If desired, you can completely bypass the default UndoEngine.UndoUnit implementation.

Constructors

UndoEngine.UndoUnit(UndoEngine, String)

Initializes a new instance of the UndoEngine.UndoUnit class.

Properties

IsEmpty

Gets a value indicating whether the UndoEngine.UndoUnit contains no events.

Name

Gets the name of the UndoEngine.UndoUnit.

UndoEngine

Gets the parent UndoEngine.

Methods

Close()

Receives a call from the undo engine to close this unit.

ComponentAdded(ComponentEventArgs)

Receives a call from the UndoEngine in response to a ComponentAdded event.

ComponentAdding(ComponentEventArgs)

Receives a call from the UndoEngine in response to a ComponentAdding event.

ComponentChanged(ComponentChangedEventArgs)

Receives a call from the UndoEngine in response to a ComponentChanged event.

ComponentChanging(ComponentChangingEventArgs)

Receives a call from the UndoEngine in response to a ComponentChanging event.

ComponentRemoved(ComponentEventArgs)

Receives a call from the UndoEngine in response to a ComponentRemoved event.

ComponentRemoving(ComponentEventArgs)

Receives a call from the UndoEngine in response to a ComponentRemoving event.

ComponentRename(ComponentRenameEventArgs)

Receives a call from the UndoEngine in response to a ComponentRename event.

Equals(Object)

Determines whether the specified object is equal to the current object.

(Inherited from Object)
GetHashCode()

Serves as the default hash function.

(Inherited from Object)
GetService(Type)

Gets an instance of the requested service.

GetType()

Gets the Type of the current instance.

(Inherited from Object)
MemberwiseClone()

Creates a shallow copy of the current Object.

(Inherited from Object)
ToString()

Returns a String that represents the current name of the unit.

Undo()

Performs an undo or redo action.

UndoCore()

Called by Undo() to perform an undo action.

Applies to

See also