New to Telerik UI for WinForms? Start a free 30-day trial

Selects the toggle-switch thumb's initial and disabled On theme states.

Definition

Namespace:Telerik.WinControls.UI

Assembly:Telerik.WinControls.UI.dll

Syntax:

C#
public class ToggleSwitchThumbButtonStateManager : ItemStateManager

Inheritance: objectItemStateManagerBaseItemStateManagerToggleSwitchThumbButtonStateManager

Constructors

Initializes the manager with the visual-state tree created by the thumb state factory.

C#
public ToggleSwitchThumbButtonStateManager(StateNodeBase rootState)
Parameters:rootStateStateNodeBase

The root node of the visual-state tree to evaluate.

Methods

Adds the thumb's On state to the initial state returned by the base manager.

C#
public override string GetInitialState(RadObject item)
Parameters:itemRadObject

The element whose initial theme state is requested.

Returns:

string

The base initial state combined with the On state.

Overrides: ItemStateManagerBase.GetInitialState(RadObject)

Selects Disabled.IsOn when an On thumb becomes disabled; other changes use the base state selection.

C#
public override void ItemStateChanged(RadObject senderItem, RadPropertyChangedEventArgs changeArgs)
Parameters:senderItemRadObject

The element whose state changed.

changeArgsRadPropertyChangedEventArgs

The property change that triggered the update.

Overrides: ItemStateManager.ItemStateChanged(RadObject, RadPropertyChangedEventArgs)

Accepts Disabled.IsOn in addition to state names recognized by the base manager.

C#
public override bool VerifyState(string themeRoleName, string key)
Parameters:themeRoleNamestring

The theme role being validated.

keystring

The visual-state key to validate.

Returns:

bool

true if the key is Disabled.IsOn or is accepted by the base manager.

Overrides: ItemStateManagerBase.VerifyState(string, string)