Sign in Join
FPDoc Onlineexperiment

TTreeNodes.ClearMultiSelection procedure

Member of TTreeNodespublicIn unit ComCtrls

Clears the nodes in a multi-selection and optionally the selected node on the tree view control.

Declaration

pascal
procedure ClearMultiSelection(ClearSelected: Boolean=False)

Arguments

ClearSelectedTrue to clear the Selected property on the tree view control.

Description

ClearMultiSelection is a method used to remove the internal node references used for a multi-selection range in the container. Each node in the range sets its MultiSelected property to False to remove it from the selection range. The GetNextMultiSelected method for the tree node is called to get the next node in the multi-selection. The process is repeated until there are no more nodes with their MultiSelected properties enabled.

The ClearSelected argument indicates whether the Selected node in the tree view control is cleared. When set to True, the Selected property in the Owner is set to Nil. The default value for the argument is False.

Updates to the multi-selection range are enclosed by calls to the LockSelectionChangeEvent and UnlockSelectionChangeEvent methods in the Owner control (when assigned). This prevents selection change events on the tree view control while the method is active.

See also

An experiment, built from development snapshots. Not the official Free Pascal or Lazarus documentation.