Class TUndoChangeSelection
Unit
UndoItemsScreenObjects
Declaration
type TUndoChangeSelection = class(TCustomUpdateScreenObjectDisplayUndo)
Description
TUndoChangeSelection
is used to change or restore which TScreenObjects or vertices in an individual TScreenObject are selected.
To use, Create a TUndoChangeSelection
, change the TScreenObjects that are selected, and call SetPostSelection. Then Undo and Redo can be used to restore or redo the changes in what is selected.
UndoChangeSelection := TUndoChangeSelection.Create;
try
UndoChangeSelection.SetPostSelection;
if UndoChangeSelection.SelectionChanged then
begin
frmGoPhast.UndoStack.Submit(UndoChangeSelection);
end
else
begin
UndoChangeSelection.Free;
end;
except
UndoChangeSelection.Free;
raise;
end;
Hierarchy
Overview
Fields
Methods
Description
Fields
 |
FOldChildModelScreenObjects: TList; |
|
 |
FOldSegment: TSegment2D; |
|
 |
FOldSelectedVertices: T2DBoolArray; |
FOldSelectedVertices records the selected vertices of a single TScreenObject when the TUndoChangeSelection was created.
|
 |
FOldSelectedScreenObjects: TList; |
FOldSelectedScreenObjects records the selected TScreenObjects when the TUndoChangeSelection was created.
|
 |
FOldVisibleScreenObjects: TList; |
|
 |
FNewVisibleScreenObjects: TList; |
|
 |
FUpdateVisible: boolean; |
|
Methods
 |
procedure ResetVisible(const ScreenObjects: TList); |
|
 |
procedure ResetSelection(const ScreenObjects: TList; const SelectedVertices: T2DBoolArray); |
ResetSelection sets the selected TScreenObjects and the selected vertices of a single TScreenObject to the values specified by ScreenObjects and SelectedVertices.
|
 |
procedure SetSelection(const ScreenObjects: TList; var SelectedVertices: T2DBoolArray); |
SetSelection stores the selected TScreenObjects in ScreenObjects and the selected vertices of a single TScreenObject in SelectedVertices.
|
 |
procedure StoreVisible(const ScreenObjects: TList); |
|
 |
function Description: string; override; |
Description tells what TUndoChangeSelection does.
|
 |
procedure InvalidateImages; |
InvalidateImages causes all the zoomboxes to redraw.
|
 |
constructor Create; |
Create creates an instance of TUndoChangeSelection and stores the selected TScreenObjects.
|
 |
destructor Destroy; override; |
Destroy gets rid of the instance of TUndoChangeSelection.
|
 |
procedure DoCommand; override; |
DoCommand causes the paint boxes showing the selected TScreenObjects to be invalidated.
|
 |
procedure Redo; override; |
Redo sets the selection to what it was when SetPostSelection was called.
|
 |
function SelectionChanged: boolean; |
SelectionChanged indicates whether or not the selection changed.
|
 |
procedure Undo; override; |
Undo sets the selection to what it was when the TUndoChangeSelection was created.
|
Generated by PasDoc 0.12.1 on 2013-05-13 15:42:06