|
|
|
@ -37,9 +37,16 @@ namespace Avalonia.Controls |
|
|
|
/// <summary>
|
|
|
|
/// Defines the <see cref="ContextMenu"/> property.
|
|
|
|
/// </summary>
|
|
|
|
[Obsolete("Prefer ContextFlyout")] |
|
|
|
public static readonly StyledProperty<ContextMenu?> ContextMenuProperty = |
|
|
|
AvaloniaProperty.Register<Control, ContextMenu?>(nameof(ContextMenu)); |
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
/// Defines the <see cref="ContextFlyout"/> property
|
|
|
|
/// </summary>
|
|
|
|
public static readonly StyledProperty<FlyoutBase?> ContextFlyoutProperty = |
|
|
|
AvaloniaProperty.Register<Control, FlyoutBase?>(nameof(ContextFlyout)); |
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
/// Event raised when an element wishes to be scrolled into view.
|
|
|
|
/// </summary>
|
|
|
|
@ -70,12 +77,22 @@ namespace Avalonia.Controls |
|
|
|
/// <summary>
|
|
|
|
/// Gets or sets a context menu to the control.
|
|
|
|
/// </summary>
|
|
|
|
[Obsolete("Prefer ContextFlyout")] |
|
|
|
public ContextMenu? ContextMenu |
|
|
|
{ |
|
|
|
get => GetValue(ContextMenuProperty); |
|
|
|
set => SetValue(ContextMenuProperty, value); |
|
|
|
} |
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
/// Gets or sets a context flyout to the control
|
|
|
|
/// </summary>
|
|
|
|
public FlyoutBase? ContextFlyout |
|
|
|
{ |
|
|
|
get => GetValue(ContextFlyoutProperty); |
|
|
|
set => SetValue(ContextFlyoutProperty, value); |
|
|
|
} |
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
/// Gets or sets a user-defined object attached to the control.
|
|
|
|
/// </summary>
|
|
|
|
|