Table of Contents

Method EnsureSideBarChild

Namespace
Alternet.UI
Assembly
Alternet.UI.Common.dll

EnsureSideBarChild<T>(SplitPanelPosition, string?, Action<T>?, Action<T>?, EnsureSideBarChildFlags)

Ensures that a child control of type T exists within the sidebar panel at the specified position.

public virtual T EnsureSideBarChild<T>(SplitPanelPosition position, string? title, Action<T>? onCreate = null, Action<T>? onUpdate = null, TabControl.EnsureSideBarChildFlags flags = EnsureSideBarChildFlags.None) where T : AbstractControl, new()

Parameters

position SplitPanelPosition

The position of the sidebar panel where the control should be ensured.

title string

The title of the child control.

onCreate Action<T>

The action to execute when creating the child control.

onUpdate Action<T>

The action to execute when updating the child control.

flags TabControl.EnsureSideBarChildFlags

Returns

T

The ensured child control of type T within the specified sidebar panel.

Type Parameters

T

The type of the control to ensure, which must derive from AbstractControl and have a parameterless constructor.