Class RibbonContextMenu
Represents a pop-up menu that enables a control to expose functionality that is specific to the context of the control.
Inheritance
Implements
Namespace: Syncfusion.Windows.Tools.Controls
Assembly: Syncfusion.Tools.Wpf.dll
Syntax
public class RibbonContextMenu : ContextMenu, IDisposable
Constructors
RibbonContextMenu()
Initializes a new instance of the RibbonContextMenu class.
Declaration
public RibbonContextMenu()
Fields
CustomContextMenuItemsProperty
Add custom context menu item in existing Ribobn context menu. This is a attached property.
Declaration
public static readonly DependencyProperty CustomContextMenuItemsProperty
Field Value
Type |
---|
System.Windows.DependencyProperty |
IsCustomContextMenuItemsOnTopProperty
Add custom context menu item in existing Ribobn context menu. This is a attached property.
Declaration
public static readonly DependencyProperty IsCustomContextMenuItemsOnTopProperty
Field Value
Type |
---|
System.Windows.DependencyProperty |
Methods
Dispose()
Disposes the unmanaged resources of ribbon context menu.
Declaration
public void Dispose()
GetCustomContextMenuItems(DependencyObject)
Gets the custom context menu items.
Declaration
public static RibbonCustomContextMenuItems GetCustomContextMenuItems(DependencyObject obj)
Parameters
Type | Name | Description |
---|---|---|
System.Windows.DependencyObject | obj | The obj. |
Returns
Type |
---|
RibbonCustomContextMenuItems |
GetIsCustomContextMenuItemsOnTop(DependencyObject)
Gets the is custom context menu items on top.
Declaration
public static bool GetIsCustomContextMenuItemsOnTop(DependencyObject obj)
Parameters
Type | Name | Description |
---|---|---|
System.Windows.DependencyObject | obj | The obj. |
Returns
Type |
---|
System.Boolean |
OnClosed(RoutedEventArgs)
Called when the System.Windows.Controls.ContextMenu.Closed event occurs.
Declaration
protected override void OnClosed(RoutedEventArgs e)
Parameters
Type | Name | Description |
---|---|---|
System.Windows.RoutedEventArgs | e | The event data for the System.Windows.Controls.ContextMenu.Closed event. |
OnKeyDown(KeyEventArgs)
Called when a System.Windows.ContentElement.KeyDown event is raised by an object inside the System.Windows.Controls.ContextMenu.
Declaration
protected override void OnKeyDown(KeyEventArgs e)
Parameters
Type | Name | Description |
---|---|---|
System.Windows.Input.KeyEventArgs | e | The event data for the System.Windows.UIElement.KeyDown event. |
OnOpened(RoutedEventArgs)
Overrides OnOpened method to perform custom action of menu elements.
Declaration
protected override void OnOpened(RoutedEventArgs e)
Parameters
Type | Name | Description |
---|---|---|
System.Windows.RoutedEventArgs | e | The instance containing the event data. |
SetCustomContextMenuItems(DependencyObject, RibbonCustomContextMenuItems)
Sets the custom context menu items.
Declaration
public static void SetCustomContextMenuItems(DependencyObject obj, RibbonCustomContextMenuItems value)
Parameters
Type | Name | Description |
---|---|---|
System.Windows.DependencyObject | obj | The obj. |
RibbonCustomContextMenuItems | value | The value. |
SetIsCustomContextMenuItemsOnTop(DependencyObject, Boolean)
Sets the is custom context menu items on top.
Declaration
public static void SetIsCustomContextMenuItemsOnTop(DependencyObject obj, bool value)
Parameters
Type | Name | Description |
---|---|---|
System.Windows.DependencyObject | obj | The obj. |
System.Boolean | value | if set to |