C# Class NanoByte.Common.Undo.MultiPropertyTracker

Tracks values in PropertyGrids in order to be able to generate MultiPropertyChangedCommands after a property was changed.
Datei anzeigen Open project: nano-byte/common

Public Methods

Method Description
GetCommand ( System.Windows.Forms.GridItem changedItem ) : IUndoCommand

Creates an undo command representing a property change the PropertyGrid has just performed.

MultiPropertyTracker ( System.Windows.Forms.PropertyGrid propertyGrid ) : System

Creates a new multi-property tracker.

Private Methods

Method Description
MoveOutOfNested ( System.Windows.Forms.GridItem item ) : System.Windows.Forms.GridItem

Moves up a hierachy of nested properties to the top element that is still a property.

SelectionChanged ( object sender, System.Windows.Forms.SelectedGridItemChangedEventArgs e ) : void

Reacts to any focus change in the PropertyGrid and creates backups of the current values before the user can change them.

Method Details

GetCommand() public method

Creates an undo command representing a property change the PropertyGrid has just performed.
public GetCommand ( System.Windows.Forms.GridItem changedItem ) : IUndoCommand
changedItem System.Windows.Forms.GridItem The property grid item that was changed.
return IUndoCommand

MultiPropertyTracker() public method

Creates a new multi-property tracker.
public MultiPropertyTracker ( System.Windows.Forms.PropertyGrid propertyGrid ) : System
propertyGrid System.Windows.Forms.PropertyGrid The property grid being tracked.
return System