Table of Contents

Class ControlStateObjects<T>

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

Specifies a set of objects for different control states.

public class ControlStateObjects<T> : ImmutableObject, IBaseObject, IDisposableObject, IDisposable, INotifyPropertyChanged

Type Parameters

T
Inheritance
ControlStateObjects<T>
Implements
Derived

Properties

ChangedHandler

Gets or sets IControlStateObjectChanged object which is used for the notifications.

Disabled

Gets or sets an object for disabled control state.

Focused

Gets or sets an object for normal control state.

HasDisabled

Gets whether Disabled property is assigned.

HasFocused

Gets whether Focused property is assigned.

HasHovered

Gets whether Hovered property is assigned.

HasNormal

Gets whether Normal property is assigned.

HasOtherStates

Gets whether there are other data for states except Normal.

HasPressed

Gets whether Pressed property is assigned.

Hovered

Gets or sets an object for hovered control state.

Normal

Gets or sets an object for normal control state.

Pressed

Gets or sets an object for pressed control state.

Methods

Assign(ControlStateObjects<T>?)

Assigns data for all states from the source.

GetObjectOrAction(VisualControlState, Func<T>)

Gets an object for the specified state or calls an action if object for that state is not specified.

GetObjectOrDefault(VisualControlState, T)

Gets an object for the specified state or defaultValue if object for that state is not specified.

GetObjectOrNormal(VisualControlState)

Gets an object for the specified state or Normal if object for that state is not specified.

GetObjectOrNull(VisualControlState)

Gets an object for the specified state or null if image for that state is not specified.

HasObject(VisualControlState)

Gets whether a value is assigned for the specified state.

SetAll(T?)

Sets data for all the states with the value.

SetObject(T?, VisualControlState)

Sets an object for the specified state.

Events

DisabledChanged

Occurs when Disabled property changes.

FocusedChanged

Occurs when Focused property changes.

HoveredChanged

Occurs when Hovered property changes.

NormalChanged

Occurs when Normal property changes.

PressedChanged

Occurs when Pressed property changes.