public static void OnPointerWheelChanged(global::Uno.Platform.PointerEventArgs args) { object origin = null; origin = global::Uno.Application.Current.Window; if (MouseSource.PointerWheelChanged != null) { MouseSource.PointerWheelChanged(origin, args); } }
public static void OnPointerLeft(global::Uno.Platform.PointerEventArgs args) { object origin = null; origin = global::Uno.Application.Current.Window; MouseSource._hasPointerEntered = false; if (MouseSource.PointerLeft != null) { MouseSource.PointerLeft(origin, args); } }
public static bool OnMouseUp(global::Uno.Runtime.Implementation.PlatformWindowHandle handle, int x, int y, global::Uno.Platform.MouseButton button) { global::Uno.Application app = global::Uno.Application.Current; if (app == null) { return(false); } global::Uno.Platform.PointerEventArgs args = new global::Uno.Platform.PointerEventArgs(global::Uno.Platform.PointerType.Mouse, Bootstrapper.GetEventModifiers(handle), button == global::Uno.Platform.MouseButton.Left, new global::Uno.Float2((float)x, (float)y), 0, button, new global::Uno.Float2(0.0f, 0.0f), global::Uno.Platform.WheelDeltaMode.DeltaPixel); global::Uno.Platform.EventSources.MouseSource.OnPointerReleased(args); return(args.Handled); }
public static bool OnMouseWheel(global::Uno.Runtime.Implementation.PlatformWindowHandle handle, float dHori, float dVert, int wheelDeltaMode) { global::Uno.Application app = global::Uno.Application.Current; if (app == null) { return(false); } global::Uno.Platform.PointerEventArgs args = new global::Uno.Platform.PointerEventArgs(global::Uno.Platform.PointerType.Mouse, Bootstrapper.GetEventModifiers(handle), false, new global::Uno.Float2((float)Bootstrapper._lastMouseX, (float)Bootstrapper._lastMouseY), 0, 0, new global::Uno.Float2(dHori, dVert), (global::Uno.Platform.WheelDeltaMode)wheelDeltaMode); global::Uno.Platform.EventSources.MouseSource.OnPointerWheelChanged(args); return(args.Handled); }
public static bool OnMouseOut(global::Uno.Runtime.Implementation.PlatformWindowHandle handle) { global::Uno.Application app = global::Uno.Application.Current; if (app == null) { return(false); } global::Uno.Platform.EventModifiers modifiers = Bootstrapper.GetEventModifiers(handle); global::Uno.Platform.PointerEventArgs args = new global::Uno.Platform.PointerEventArgs(global::Uno.Platform.PointerType.Mouse, modifiers, modifiers.HasFlag(global::Uno.Platform.EventModifiers.LeftButton), new global::Uno.Float2(0.0f, 0.0f), 0, 0, new global::Uno.Float2(0.0f, 0.0f), global::Uno.Platform.WheelDeltaMode.DeltaPixel); global::Uno.Platform.EventSources.MouseSource.OnPointerLeft(args); return(args.Handled); }
public static void OnPointerMoved(global::Uno.Platform.PointerEventArgs args) { object origin = null; origin = global::Uno.Application.Current.Window; if (!MouseSource._hasPointerEntered) { MouseSource.OnPointerEntered(args); } if (MouseSource.PointerMoved != null) { MouseSource.PointerMoved(origin, args); } }
public static bool OnTouchMove(global::Uno.Runtime.Implementation.PlatformWindowHandle handle, float x, float y, int id) { global::Uno.Application app = global::Uno.Application.Current; if (Bootstrapper._fingerCount == 1) { Bootstrapper._lastPrimaryFingerId = id; } if (app == null) { return(false); } global::Uno.Platform.PointerEventArgs args = new global::Uno.Platform.PointerEventArgs(global::Uno.Platform.PointerType.Touch, Bootstrapper.GetEventModifiers(handle), Bootstrapper.IsPrimaryFinger(handle, id), new global::Uno.Float2(x, y), id, 0, new global::Uno.Float2(0.0f, 0.0f), global::Uno.Platform.WheelDeltaMode.DeltaPixel); global::Uno.Platform.EventSources.MouseSource.OnPointerMoved(args); return(args.Handled); }