Class MouseEventArgs
Provides event data for pointer message events related to specific user interface elements, such as PointerPressed.
Inheritance
Inherited Members
Namespace: System.Windows.Input
Assembly: OpenSilver.dll
Syntax
public class MouseEventArgs : RoutedEventArgs
Properties
| Improve this Doc View SourceClickCount
Gets the number of times the button was clicked.
Declaration
public int ClickCount { get; }
Property Value
Type | Description |
---|---|
System.Int32 |
Delta
Declaration
[NotImplemented]
public int Delta { get; }
Property Value
Type | Description |
---|---|
System.Int32 |
Handled
Gets or sets a value that marks the routed event as handled, and prevents most handlers along the event route from handling the same event again.
Declaration
public bool Handled { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean |
KeyModifiers
Gets a value that indicates which key modifiers were active at the time that the pointer event was initiated.
Declaration
public ModifierKeys KeyModifiers { get; }
Property Value
Type | Description |
---|---|
ModifierKeys |
Pointer
Gets a reference to a pointer token.
Declaration
public Pointer Pointer { get; }
Property Value
Type | Description |
---|---|
Pointer |
StylusDevice
Gets an object that reports stylus device information, such as the collection of stylus points associated with the input.
Declaration
public StylusDevice StylusDevice { get; }
Property Value
Type | Description |
---|---|
StylusDevice | The stylus device information object. |
Methods
| Improve this Doc View SourceGetPosition(UIElement)
Returns the pointer position for this event occurrence, optionally evaluated against a coordinate origin of a supplied UIElement.
Declaration
public Point GetPosition(UIElement relativeTo)
Parameters
Type | Name | Description |
---|---|---|
UIElement | relativeTo | Any UIElement-derived object that is connected to the same object tree. To specify the object relative to the overall coordinate system, use a relativeTo value of null. |
Returns
Type | Description |
---|---|
Point | A PointerPoint value that represents the pointer point associated with this event. If null was passed as relativeTo, the coordinates are in the frame of reference of the overall window. If a non-null relativeTo was passed, the coordinates are relative to the object referenced by relativeTo. |
SetPointerAbsolutePosition(Object, Window)
Declaration
protected void SetPointerAbsolutePosition(object jsEventArg, Window window)
Parameters
Type | Name | Description |
---|---|---|
System.Object | jsEventArg | |
Window | window |