[]
Represents a button with a dropdown area that is shown when the button is clicked, and hides when the mouse is clicked outside the control.
[TemplatePart(Name = "PART_DropDownButton", Type = typeof(ToggleButton))]
public class DropDownButton : ContentControl, IAnimatable, IFrameworkInputElement, IInputElement, ISupportInitialize, IQueryAmbient, IAddChild, ICommandSource
Name | Description |
---|---|
DropDownButton() | Initializes a new instance of the DropDownButton class. |
Name | Description |
---|---|
AutoCloseProperty | Identifies the AutoClose dependency property. |
ButtonStyleKeyProperty | Identifies the ButtonStyleKey dependency property. |
ClickEvent | Identifies the Click event. |
ClosedEvent | Identifies the Closed event. |
CommandParameterProperty | Identifies the CommandParameter dependency property. |
CommandProperty | Identifies the Command dependency property. |
CommandTargetProperty | Identifies the CommandTarget dependency property. |
DropDownContentProperty | Identifies the DropDownContent dependency property. |
IsOpenProperty | Identifies the IsOpen dependency property. |
OpenedEvent | Identifies the Opened event. |
Name | Description |
---|---|
AutoClose | Gets or sets a value indicating whether the dropdown should be collapsed automatically. |
Button | Gets or sets the ButtonBase of the DropDownButton. |
ButtonStyleKey | Gets or sets the button style. |
Command | Gets or sets the command that will be executed when the command source is invoked. |
CommandParameter | Gets or sets a user-defined data value that can be passed to the command when it is executed. |
CommandTarget | Gets or sets the object that the command is being executed on. |
DropDownContent | Gets or sets the content that is shown when the dropdown is expanded. |
IsOpen | Gets or sets a value indicating whether this dropdown is open. |
Name | Description |
---|---|
OnApplyTemplate() | Called when the control template is applied. |
OnClick() | Raises click event. |
OnCommandChanged(ICommand, ICommand) | Raises when command changeds |
OnIsOpenChanged(bool, bool) | Raises the opened event or closed event for the DropDownButton. |
OnMouseUp(MouseButtonEventArgs) | Invoked on MouseUp event, closes dropdown if necessary |
Name | Description |
---|---|
Click | Occurs when the user clicks the control. |
Closed | Occurs when the dropdown is closed. |
Opened | Occurs when the dropdown is opened. |