Table of Contents

TAdvCustomComponentComboBox Class

Abstract base combo box that lists all components owned by a root component and keeps selection synchronized with a component inspector.

Remarks

TAdvCustomComponentComboBox extends TCustomComboBox to populate its items from the component hierarchy rooted at Root. Selecting an item automatically updates the Instance property of a linked TAdvCustomComponentInspector, and inspector changes are reflected back in the combo selection. Override Filter to restrict which components appear in the list.

Syntax

Unit: ComponentInspector

TAdvCustomComponentComboBox = class(TCustomComboBox);

Constructors

Name Description
Create Creates a TAdvCustomComponentComboBox and initializes it as a drop-down list.

Methods

Name Description
RefreshList Clears and repopulates the combo list from the components owned by Root.
SynchroLock Increments the synchronization lock counter to suppress change notifications during batch updates.
SynchroUnlock Decrements the synchronization lock counter and re-enables change notifications.

Properties

Name Description
ComponentInspector Gets or sets the linked component inspector that is kept in sync with the combo selection.
Instance Gets or sets the currently selected component, synchronizing with the linked inspector when changed.
Root Gets or sets the root component whose owned components are listed in the combo box.

Events

Name Description
OnFilter Fired for each candidate component when building the list, allowing the handler to exclude specific components.
OnGetComponentText Fired when the display text for a component is needed, allowing the handler to customize the label shown in the list.