Represents a context menu that can host any bar control.
- Inheritance:
-
object
Visual
UIElement
Framework
Element Control ItemsControl MenuBase ContextMenu object
Constructors
BarContextMenu()
Initializes a new instance of the Bar
Properties
IsMiniToolBarAbove
Gets whether the mini-toolbar is above the menu.
Property Value
- bool:
true
if the mini-toolbar is above the menu; otherwise,false
.
MiniToolBar
Gets the Mini
Property Value
- Mini
Tool :Bar The Mini
Tool in use.Bar
MiniToolBarContent
Gets or sets the mini-toolbar.
Property Value
- object:
The mini-toolbar, which can either be a mini-toolbar view model that uses Item
Container for its UI, or a MiniTemplate Selector Tool control instance.Bar
MiniToolBarStyle
Gets or sets the Style that targets Mini
Property Value
- Style:
The Style that targets Mini
Tool .Bar
Methods
ClearContainerForItemOverride(DependencyObject, object)
When overridden in a derived class, undoes the effects of the Prepare
Parameter | Type | Description |
---|---|---|
element | DependencyObject | The container element. |
item | object | The item. |
GetContainerForItemOverride()
Creates or identifies the element used to display the specified item.
Returns
- DependencyObject:
The element used to display the specified item.
IsItemItsOwnContainerOverride(object)
Determines whether the specified item is, or is eligible to be, its own item container.
Parameter | Type | Description |
---|---|---|
item | object | The item to check whether it is an item container. |
Returns
OnApplyTemplate()
When overridden in a derived class, is invoked whenever application code or internal processes call Apply
OnContextMenuOpening(ContextMenuEventArgs)
Invoked whenever an unhandled Context
Parameter | Type | Description |
---|---|---|
e | Context |
The Routed |
OnCreateAutomationPeer()
Creates and returns a Context
Returns
- Automation
Peer : A Context
Menu object for this ContextAutomation Peer Menu .
OnKeyDown(KeyEventArgs)
Called when a Key
Parameter | Type | Description |
---|---|---|
e | Key |
The event data for the Key |
OnOpened(RoutedEventArgs)
Called when the Opened event occurs.
Parameter | Type | Description |
---|---|---|
e | Routed |
The event data for the Opened event. |
OnPreviewGotKeyboardFocus(KeyboardFocusChangedEventArgs)
Invoked when an unhandled System.Windows.Input.Keyboard.PreviewGotKeyboardFocus attached event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event.
Parameter | Type | Description |
---|---|---|
e | Keyboard |
The Keyboard |
PrepareContainerForItemOverride(DependencyObject, object)
Prepares the specified element to display the specified item.
Parameter | Type | Description |
---|---|---|
element | DependencyObject | Element used to display the specified item. |
item | object | Specified item. |
Fields
IsMiniToolBarAboveProperty
Identifies the Is
MiniToolBarContentProperty
Identifies the Mini
MiniToolBarProperty
Identifies the Mini
MiniToolBarStyleProperty
Identifies the Mini