In This Article

EnumListBoxItem Class

Represents a selectable item in a EnumListBox.

[TemplateVisualState(Name = "Checked", GroupName = "CheckStates")]
[TemplateVisualState(Name = "Unchecked", GroupName = "CheckStates")]
[TemplateVisualState(Name = "Indeterminate", GroupName = "CheckStates")]
[TemplateVisualState(Name = "GroupNormal", GroupName = "GroupStates")]
[TemplateVisualState(Name = "GroupStart", GroupName = "GroupStates")]
public class EnumListBoxItem : ListBoxItem
Inheritance:
object Visual UIElement FrameworkElement Control ContentControl ListBoxItem object

Constructors

EnumListBoxItem()

Initializes an instance of the class.

public EnumListBoxItem()

Properties

IsFlagsEnum

Indicates whether the enumeration is a flags enumeration.

public bool IsFlagsEnum { get; }

Property Value

bool:

true if the enumeration is a flags enumeration; otherwise false.

IsGroupStart

Indicates whether the enumeration value starts a group.

public bool IsGroupStart { get; }

Property Value

bool:

true if the enumeration value starts a group; otherwise false.

IsPartiallySelected

Indicates whether the enumeration value represented by this item is partially selected.

public bool IsPartiallySelected { get; }

Property Value

bool:

true if the enumeration value represented by this item is partially selected; otherwise false.

Methods

OnApplyTemplate()

When overridden in a derived class, is invoked whenever application code or internal processes call ApplyTemplate().

public override void OnApplyTemplate()

OnMouseLeftButtonDown(MouseButtonEventArgs)

Called when the user presses the right mouse button over the ListBoxItem.

protected override void OnMouseLeftButtonDown(MouseButtonEventArgs e)
Parameter Type Description
e MouseButtonEventArgs

The event data.

Fields

IsFlagsEnumProperty

Defines the IsFlagsEnum property.

public static readonly DependencyProperty IsFlagsEnumProperty

IsGroupStartProperty

Defines the IsGroupStart property.

public static readonly DependencyProperty IsGroupStartProperty

IsPartiallySelectedProperty

Defines the IsPartiallySelected property.

public static readonly DependencyProperty IsPartiallySelectedProperty

Extension Methods