100 references to UnsafeNativeMethods
PresentationCore (100)
System\Windows\Input\Stylus\Pointer\PointerData.cs (1)
10using static MS.Win32.Pointer.UnsafeNativeMethods;
System\Windows\Input\Stylus\Pointer\PointerInteractionEngine.cs (39)
52private static List<UnsafeNativeMethods.INTERACTION_CONTEXT_CONFIGURATION> DefaultConfiguration = 53new List<UnsafeNativeMethods.INTERACTION_CONTEXT_CONFIGURATION>() 55new UnsafeNativeMethods.INTERACTION_CONTEXT_CONFIGURATION() 57enable = UnsafeNativeMethods.INTERACTION_CONFIGURATION_FLAGS.INTERACTION_CONFIGURATION_FLAG_TAP, 58interactionId = UnsafeNativeMethods.INTERACTION_ID.INTERACTION_ID_TAP 60new UnsafeNativeMethods.INTERACTION_CONTEXT_CONFIGURATION() 62enable = UnsafeNativeMethods.INTERACTION_CONFIGURATION_FLAGS.INTERACTION_CONFIGURATION_FLAG_HOLD, 63interactionId = UnsafeNativeMethods.INTERACTION_ID.INTERACTION_ID_HOLD 65new UnsafeNativeMethods.INTERACTION_CONTEXT_CONFIGURATION() 67enable = UnsafeNativeMethods.INTERACTION_CONFIGURATION_FLAGS.INTERACTION_CONFIGURATION_FLAG_SECONDARY_TAP, 68interactionId = UnsafeNativeMethods.INTERACTION_ID.INTERACTION_ID_SECONDARY_TAP 70new UnsafeNativeMethods.INTERACTION_CONTEXT_CONFIGURATION() 72enable = UnsafeNativeMethods.INTERACTION_CONFIGURATION_FLAGS.INTERACTION_CONFIGURATION_FLAG_MANIPULATION 73| UnsafeNativeMethods.INTERACTION_CONFIGURATION_FLAGS.INTERACTION_CONFIGURATION_FLAG_MANIPULATION_TRANSLATION_INERTIA 74| UnsafeNativeMethods.INTERACTION_CONFIGURATION_FLAGS.INTERACTION_CONFIGURATION_FLAG_MANIPULATION_TRANSLATION_X 75| UnsafeNativeMethods.INTERACTION_CONFIGURATION_FLAGS.INTERACTION_CONFIGURATION_FLAG_MANIPULATION_TRANSLATION_Y, 76interactionId = UnsafeNativeMethods.INTERACTION_ID.INTERACTION_ID_MANIPULATION 112private UnsafeNativeMethods.INTERACTION_CONTEXT_OUTPUT_CALLBACK _callbackDelegate; 166internal PointerInteractionEngine(PointerStylusDevice stylusDevice, List<UnsafeNativeMethods.INTERACTION_CONTEXT_CONFIGURATION> configuration = null) 179UnsafeNativeMethods.CreateInteractionContext(out interactionContext); 190UnsafeNativeMethods.SetPropertyInteractionContext(_interactionContext, 191UnsafeNativeMethods.INTERACTION_CONTEXT_PROPERTY.INTERACTION_CONTEXT_PROPERTY_FILTER_POINTERS, 195UnsafeNativeMethods.SetPropertyInteractionContext(_interactionContext, 196UnsafeNativeMethods.INTERACTION_CONTEXT_PROPERTY.INTERACTION_CONTEXT_PROPERTY_MEASUREMENT_UNITS, 197(UInt32)UnsafeNativeMethods.InteractionMeasurementUnits.Screen); 200UnsafeNativeMethods.SetInteractionConfigurationInteractionContext(_interactionContext, (uint)configuration.Count, configuration.ToArray()); 206UnsafeNativeMethods.RegisterOutputCallbackInteractionContext(_interactionContext, _callbackDelegate); 227UnsafeNativeMethods.DestroyInteractionContext(_interactionContext); 260UnsafeNativeMethods.BufferPointerPacketsInteractionContext(_interactionContext, 1, new UnsafeNativeMethods.POINTER_INFO[] { _stylusDevice.CurrentPointerInfo }); 270UnsafeNativeMethods.ProcessBufferedPacketsInteractionContext(_interactionContext); 286private void Callback(IntPtr clientData, ref UnsafeNativeMethods.INTERACTION_CONTEXT_OUTPUT output) 293case UnsafeNativeMethods.INTERACTION_ID.INTERACTION_ID_TAP: 298case UnsafeNativeMethods.INTERACTION_ID.INTERACTION_ID_SECONDARY_TAP: 303case UnsafeNativeMethods.INTERACTION_ID.INTERACTION_ID_HOLD: 307if (output.interactionFlags.HasFlag(UnsafeNativeMethods.INTERACTION_FLAGS.INTERACTION_FLAG_BEGIN)) 317case UnsafeNativeMethods.INTERACTION_ID.INTERACTION_ID_MANIPULATION: 477private SystemGesture DetectDragOrFlick(UnsafeNativeMethods.INTERACTION_CONTEXT_OUTPUT output) 481if (output.interactionFlags.HasFlag(UnsafeNativeMethods.INTERACTION_FLAGS.INTERACTION_FLAG_END))
System\Windows\Input\Stylus\Pointer\PointerStylusDevice.cs (22)
93private UnsafeNativeMethods.POINTER_DEVICE_CURSOR_INFO _cursorInfo = new UnsafeNativeMethods.POINTER_DEVICE_CURSOR_INFO(); 114internal PointerStylusDevice(PointerTabletDevice tabletDevice, UnsafeNativeMethods.POINTER_DEVICE_CURSOR_INFO cursorInfo) 196internal UnsafeNativeMethods.POINTER_INFO CurrentPointerInfo { get { return _pointerData.Info; } } 216return _pointerData?.Info.pointerFlags.HasFlag(UnsafeNativeMethods.POINTER_FLAGS.POINTER_FLAG_NEW) ?? false; 224return _pointerData?.Info.pointerFlags.HasFlag(UnsafeNativeMethods.POINTER_FLAGS.POINTER_FLAG_INCONTACT) ?? false; 232return _pointerData?.Info.pointerFlags.HasFlag(UnsafeNativeMethods.POINTER_FLAGS.POINTER_FLAG_PRIMARY) ?? false; 240return _pointerData?.Info.pointerFlags.HasFlag(UnsafeNativeMethods.POINTER_FLAGS.POINTER_FLAG_FIRSTBUTTON) ?? false; 248return _pointerData?.Info.pointerFlags.HasFlag(UnsafeNativeMethods.POINTER_FLAGS.POINTER_FLAG_SECONDBUTTON) ?? false; 256return _pointerData?.Info.pointerFlags.HasFlag(UnsafeNativeMethods.POINTER_FLAGS.POINTER_FLAG_THIRDBUTTON) ?? false; 264return _pointerData?.Info.pointerFlags.HasFlag(UnsafeNativeMethods.POINTER_FLAGS.POINTER_FLAG_FOURTHBUTTON) ?? false; 272return _pointerData?.Info.pointerFlags.HasFlag(UnsafeNativeMethods.POINTER_FLAGS.POINTER_FLAG_FIFTHBUTTON) ?? false; 288return _pointerData?.Info.pointerFlags.HasFlag(UnsafeNativeMethods.POINTER_FLAGS.POINTER_FLAG_DOWN) ?? false; 296return _pointerData?.Info.pointerFlags.HasFlag(UnsafeNativeMethods.POINTER_FLAGS.POINTER_FLAG_UPDATE) ?? false; 304return _pointerData?.Info.pointerFlags.HasFlag(UnsafeNativeMethods.POINTER_FLAGS.POINTER_FLAG_UP) ?? false; 312return _pointerData?.Info.pointerFlags.HasFlag(UnsafeNativeMethods.POINTER_FLAGS.POINTER_FLAG_CAPTURECHANGED) ?? false; 320return _pointerData?.Info.pointerFlags.HasFlag(UnsafeNativeMethods.POINTER_FLAGS.POINTER_FLAG_HASTRANSFORM) ?? false; 424return (_cursorInfo.cursor == UnsafeNativeMethods.POINTER_DEVICE_CURSOR_TYPE.POINTER_DEVICE_CURSOR_TYPE_ERASER) 452return !(_pointerData?.Info.pointerFlags.HasFlag(UnsafeNativeMethods.POINTER_FLAGS.POINTER_FLAG_INCONTACT) ?? false) 453&& (_pointerData?.Info.pointerFlags.HasFlag(UnsafeNativeMethods.POINTER_FLAGS.POINTER_FLAG_INRANGE) ?? false); 465&& (_pointerData?.PenInfo.penFlags.HasFlag(UnsafeNativeMethods.PEN_FLAGS.PEN_FLAG_INVERTED) ?? false); 476return _pointerData?.Info.pointerFlags.HasFlag(UnsafeNativeMethods.POINTER_FLAGS.POINTER_FLAG_INRANGE) ?? false;
System\Windows\Input\Stylus\Pointer\PointerStylusPointPropertyInfoHelper.cs (1)
63internal static StylusPointPropertyInfo CreatePropertyInfo(UnsafeNativeMethods.POINTER_DEVICE_PROPERTY prop)
System\Windows\Input\Stylus\Pointer\PointerTabletDevice.cs (4)
102if (UnsafeNativeMethods.GetPointerDeviceCursors(_deviceInfo.Device, ref cursorCount, null)) 104UnsafeNativeMethods.POINTER_DEVICE_CURSOR_INFO[] cursors = new UnsafeNativeMethods.POINTER_DEVICE_CURSOR_INFO[cursorCount]; 106if (UnsafeNativeMethods.GetPointerDeviceCursors(_deviceInfo.Device, ref cursorCount, cursors))
System\Windows\Input\Stylus\Pointer\PointerTabletDeviceCollection.cs (4)
90IsValid = UnsafeNativeMethods.GetPointerDevices(ref deviceCount, null); 94UnsafeNativeMethods.POINTER_DEVICE_INFO[] deviceInfos 95= new UnsafeNativeMethods.POINTER_DEVICE_INFO[deviceCount]; 97IsValid = UnsafeNativeMethods.GetPointerDevices(ref deviceCount, deviceInfos);
System\Windows\Input\Stylus\Pointer\PointerTabletDeviceInfo.cs (23)
25private UnsafeNativeMethods.POINTER_DEVICE_INFO _deviceInfo; 34internal UnsafeNativeMethods.POINTER_DEVICE_PROPERTY[] SupportedPointerProperties { get; private set; } 60internal UnsafeNativeMethods.RECT DeviceRect { get; private set; } = new UnsafeNativeMethods.RECT(); 65internal UnsafeNativeMethods.RECT DisplayRect { get; private set; } = new UnsafeNativeMethods.RECT(); 75internal PointerTabletDeviceInfo(int id, UnsafeNativeMethods.POINTER_DEVICE_INFO deviceInfo) 121case UnsafeNativeMethods.POINTER_DEVICE_TYPE.POINTER_DEVICE_TYPE_EXTERNAL_PEN: 126case UnsafeNativeMethods.POINTER_DEVICE_TYPE.POINTER_DEVICE_TYPE_INTEGRATED_PEN: 132case UnsafeNativeMethods.POINTER_DEVICE_TYPE.POINTER_DEVICE_TYPE_TOUCH: 138case UnsafeNativeMethods.POINTER_DEVICE_TYPE.POINTER_DEVICE_TYPE_TOUCH_PAD: 182success = UnsafeNativeMethods.GetPointerDeviceProperties(Device, ref propCount, null); 186SupportedPointerProperties = new UnsafeNativeMethods.POINTER_DEVICE_PROPERTY[propCount]; 188success = UnsafeNativeMethods.GetPointerDeviceProperties(Device, ref propCount, SupportedPointerProperties); 203List<UnsafeNativeMethods.POINTER_DEVICE_PROPERTY> supportedProperties = new List<UnsafeNativeMethods.POINTER_DEVICE_PROPERTY>() 205new UnsafeNativeMethods.POINTER_DEVICE_PROPERTY(), 206new UnsafeNativeMethods.POINTER_DEVICE_PROPERTY(), 209List<UnsafeNativeMethods.POINTER_DEVICE_PROPERTY> supportedButtonProperties = new List<UnsafeNativeMethods.POINTER_DEVICE_PROPERTY>(); 294var deviceRect = new UnsafeNativeMethods.RECT(); 295var displayRect = new UnsafeNativeMethods.RECT(); 297success = UnsafeNativeMethods.GetPointerDeviceRects(_deviceInfo.device, ref deviceRect, ref displayRect);
System\Windows\InterOp\HwndPointerInputProvider.cs (6)
150if (UnsafeNativeMethods.GetRawPointerDeviceData( 220&& (data.Info.pointerType == UnsafeNativeMethods.POINTER_INPUT_TYPE.PT_TOUCH 221|| data.Info.pointerType == UnsafeNativeMethods.POINTER_INPUT_TYPE.PT_PEN)) 225if (UnsafeNativeMethods.GetPointerCursorId(pointerId, ref cursorId)) 238&& (!data.Info.pointerFlags.HasFlag(UnsafeNativeMethods.POINTER_FLAGS.POINTER_FLAG_INCONTACT) 239&& data.Info.pointerFlags.HasFlag(UnsafeNativeMethods.POINTER_FLAGS.POINTER_FLAG_INRANGE)))