Class AccordionItem
Represents a control that displays a header and has a collapsible content window.
Inheritance
Inherited Members
Namespace: System.Windows.Controls
Assembly: Controls.Layout.Toolkit.OpenSilver.dll
Syntax
public class AccordionItem : HeaderedContentControl
Constructors
| Improve this Doc View SourceAccordionItem()
Initializes a new instance of the AccordionItem class.
Declaration
public AccordionItem()
Fields
| Improve this Doc View SourceAccordionButtonStyleProperty
Identifies the AccordionButtonStyle dependency property.
Declaration
public static readonly DependencyProperty AccordionButtonStyleProperty
Field Value
Type | Description |
---|---|
DependencyProperty |
ContentTargetSizeProperty
Identifies the ContentTargetSize dependency property.
Declaration
public static readonly DependencyProperty ContentTargetSizeProperty
Field Value
Type | Description |
---|---|
DependencyProperty |
ExpandableContentControlStyleProperty
Identifies the ExpandableContentControlStyle dependency property.
Declaration
public static readonly DependencyProperty ExpandableContentControlStyleProperty
Field Value
Type | Description |
---|---|
DependencyProperty |
ExpandDirectionProperty
Identifies the ExpandDirection dependency property.
Declaration
public static readonly DependencyProperty ExpandDirectionProperty
Field Value
Type | Description |
---|---|
DependencyProperty |
IsSelectedProperty
Identifies the IsSelected dependency property.
Declaration
public static readonly DependencyProperty IsSelectedProperty
Field Value
Type | Description |
---|---|
DependencyProperty |
Properties
| Improve this Doc View SourceAccordionButtonStyle
Gets or sets the Style used by AccordionButton.
Declaration
public Style AccordionButtonStyle { get; set; }
Property Value
Type | Description |
---|---|
Style |
ContentTargetSize
Gets the Size that the content will animate to.
Declaration
public Size ContentTargetSize { get; }
Property Value
Type | Description |
---|---|
Size |
ExpandableContentControlStyle
Gets or sets the Style used by ExpandableContentControl.
Declaration
public Style ExpandableContentControlStyle { get; set; }
Property Value
Type | Description |
---|---|
Style |
ExpandDirection
Gets the direction in which the AccordionItem content window opens.
Declaration
public ExpandDirection ExpandDirection { get; protected set; }
Property Value
Type | Description |
---|---|
ExpandDirection |
IsLocked
Gets a value indicating whether the AccordionItem cannot be selected by the user.
Declaration
public bool IsLocked { get; }
Property Value
Type | Description |
---|---|
System.Boolean |
|
Remarks
The IsSelected property may not be changed when the AccordionItem is locked. Locking occurs when the item is the first in the list, the SelectionMode of Accordion requires atleast one selected AccordionItem and the AccordionItem is currently selected.
IsSelected
Gets or sets a value indicating whether the AccordionItem is selected and its content window is visible.
Declaration
public bool IsSelected { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean |
Methods
| Improve this Doc View SourceOnAccordionButtonStyleChanged(Style, Style)
Called when AccordionButtonStyle is changed.
Declaration
protected virtual void OnAccordionButtonStyleChanged(Style oldStyle, Style newStyle)
Parameters
Type | Name | Description |
---|---|---|
Style | oldStyle | The old style. |
Style | newStyle | The new style. |
OnApplyTemplate()
Builds the visual tree for the AccordionItem control when a new template is applied.
Declaration
public override void OnApplyTemplate()
Overrides
| Improve this Doc View SourceOnCreateAutomationPeer()
Returns a AccordionItemAutomationPeer for use by the Silverlight automation infrastructure.
Declaration
protected override AutomationPeer OnCreateAutomationPeer()
Returns
Type | Description |
---|---|
AutomationPeer | A AccordionItemAutomationPeer object for the AccordionItem. |
Overrides
| Improve this Doc View SourceOnExpandableContentControlStyleChanged(Style, Style)
Called when ExpandableContentControlStyle is changed.
Declaration
protected virtual void OnExpandableContentControlStyleChanged(Style oldStyle, Style newStyle)
Parameters
Type | Name | Description |
---|---|---|
Style | oldStyle | The old style. |
Style | newStyle | The new style. |
OnGotFocus(RoutedEventArgs)
Provides handling for the GotFocus event.
Declaration
protected override void OnGotFocus(RoutedEventArgs e)
Parameters
Type | Name | Description |
---|---|---|
RoutedEventArgs | e | The data for the event. |
Overrides
| Improve this Doc View SourceOnKeyDown(KeyEventArgs)
Provides handling for the KeyDown event.
Declaration
protected override void OnKeyDown(KeyEventArgs e)
Parameters
Type | Name | Description |
---|---|---|
KeyEventArgs | e | Key event args. |
Overrides
| Improve this Doc View SourceOnLostFocus(RoutedEventArgs)
Provides handling for the LostFocus event.
Declaration
protected override void OnLostFocus(RoutedEventArgs e)
Parameters
Type | Name | Description |
---|---|---|
RoutedEventArgs | e | The data for the event. |
Overrides
| Improve this Doc View SourceOnMouseEnter(MouseEventArgs)
Provides handling for the MouseEnter event.
Declaration
protected override void OnMouseEnter(MouseEventArgs e)
Parameters
Type | Name | Description |
---|---|---|
MouseEventArgs | e | The data for the event. |
Overrides
| Improve this Doc View SourceOnMouseLeave(MouseEventArgs)
Provides handling for the MouseLeave event.
Declaration
protected override void OnMouseLeave(MouseEventArgs e)
Parameters
Type | Name | Description |
---|---|---|
MouseEventArgs | e | The data for the event. |
Overrides
| Improve this Doc View SourceOnMouseLeftButtonDown(MouseButtonEventArgs)
Provides handling for the MouseLeftButtonDown event.
Declaration
protected override void OnMouseLeftButtonDown(MouseButtonEventArgs e)
Parameters
Type | Name | Description |
---|---|---|
MouseButtonEventArgs | e | The data for the event. |
Overrides
| Improve this Doc View SourceOnMouseLeftButtonUp(MouseButtonEventArgs)
Called before the MouseLeftButtonUp event occurs.
Declaration
protected override void OnMouseLeftButtonUp(MouseButtonEventArgs e)
Parameters
Type | Name | Description |
---|---|---|
MouseButtonEventArgs | e | The data for the event. |
Overrides
| Improve this Doc View SourceOnSelected()
Raises the Selected event when the IsSelected property changes from false to true.
Declaration
protected virtual void OnSelected()
OnUnselected()
Raises the Unselected event when the IsSelected property changes from true to false.
Declaration
protected virtual void OnUnselected()
Events
| Improve this Doc View SourceSelected
Occurs when the accordionItem is selected.
Declaration
public event RoutedEventHandler Selected
Event Type
Type | Description |
---|---|
RoutedEventHandler |
Unselected
Occurs when the accordionItem is unselected.
Declaration
public event RoutedEventHandler Unselected
Event Type
Type | Description |
---|---|
RoutedEventHandler |