Table of Contents

Class PopupAdorner

Namespace
Tudormobile.Wpf.Adorners
Assembly
Tudormobile.WpfControls.dll

A custom adorner that displays a popup glyph (down arrow or right arrow) on the adorned element. The glyph indicates responds to MouseOver and MouseDown events to provide visual feedback (consistent with the adorned element's foreground color) and displays the PopupContent (via attached property) of the adorned element as either a ContextMenu, a Popup control, or as an arbitrary framework element hosted in a Popup control.

public class PopupAdorner : GlyphAdorner, IAnimatable, ISupportInitialize, IFrameworkInputElement, IInputElement, IQueryAmbient
Inheritance
PopupAdorner
Implements
Inherited Members

Constructors

PopupAdorner(UIElement)

Creates a new instance of the PopupAdorner class, which adorns the specified UI element with an interactive popup glyph.

public PopupAdorner(UIElement adornedElement)

Parameters

adornedElement UIElement

The UI element to be adorned with the popup glyph. This element will receive the visual overlay and interactive behavior provided by the PopupAdorner. Must not be null and must be a FrameworkElement.

Methods

OnMouseEnter(MouseEventArgs)

Invoked when an unhandled System.Windows.Input.Mouse.MouseEnter attached event is raised on this element. Implement this method to add class handling for this event.

protected override void OnMouseEnter(MouseEventArgs e)

Parameters

e MouseEventArgs

The MouseEventArgs that contains the event data.

OnMouseLeave(MouseEventArgs)

Invoked when an unhandled System.Windows.Input.Mouse.MouseLeave attached event is raised on this element. Implement this method to add class handling for this event.

protected override void OnMouseLeave(MouseEventArgs e)

Parameters

e MouseEventArgs

The MouseEventArgs that contains the event data.

OnMouseLeftButtonDown(MouseButtonEventArgs)

Invoked when an unhandled MouseLeftButtonDown routed event is raised on this element. Implement this method to add class handling for this event.

protected override void OnMouseLeftButtonDown(MouseButtonEventArgs e)

Parameters

e MouseButtonEventArgs

The MouseButtonEventArgs that contains the event data. The event data reports that the left mouse button was pressed.

OnMouseLeftButtonUp(MouseButtonEventArgs)

Invoked when an unhandled MouseLeftButtonUp routed event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event.

protected override void OnMouseLeftButtonUp(MouseButtonEventArgs e)

Parameters

e MouseButtonEventArgs

The MouseButtonEventArgs that contains the event data. The event data reports that the left mouse button was released.

OnRender(DrawingContext)

When overridden in a derived class, participates in rendering operations that are directed by the layout system. The rendering instructions for this element are not used directly when this method is invoked, and are instead preserved for later asynchronous use by layout and drawing.

protected override void OnRender(DrawingContext drawingContext)

Parameters

drawingContext DrawingContext

The drawing instructions for a specific element. This context is provided to the layout system.