private LcdCalibrationView(ITouchDevice device) { this.device = device; this.InitializeComponent(); _LoadTask = new TaskCompletionSource<object>(); this.Loaded += (s, e) => _LoadTask.SetResult(null); }
private LcdCalibrationView(ITouchDevice device) { this.device = device; this.InitializeComponent(); _LoadTask = new TaskCompletionSource <object>(); this.Loaded += (s, e) => _LoadTask.SetResult(null); }
public TouchProcessor(ITouchDevice device) { if (device == null) { throw new ArgumentNullException(nameof(device)); } this.device = device; }
private TouchProcessor InitializeTouchProcessor(ITouchDevice touchDevice) { var processor = new TouchProcessor(touchDevice); processor.PointerDown += TouchedDown; processor.PointerUp += TouchedUp; return(processor); }
public TouchSensor(ITouchDevice device) { _grid = device.GetScreenState(); _orientations = new[] { new Orientation(0, 1), new Orientation(0, -1), new Orientation(1, 0), new Orientation(-1, 0), }; }
public static async Task<AffineTransformationParameters> CalibrateScreenAsync(ITouchDevice device, CalibrationStyle style = CalibrationStyle.CornersAndCenter) { var bounds = Windows.UI.Core.CoreWindow.GetForCurrentThread().Bounds; LcdCalibrationView view = new LcdCalibrationView(device); view.Width = bounds.Width; view.Height = bounds.Height; Popup p = new Popup() { Child = view, Margin = new Thickness(0), IsOpen = true }; try { return await view.CalibrateAsync(style); } finally { p.IsOpen = false; } }
public static async Task <AffineTransformationParameters> CalibrateScreenAsync(ITouchDevice device, CalibrationStyle style = CalibrationStyle.CornersAndCenter) { var bounds = Windows.UI.Core.CoreWindow.GetForCurrentThread().Bounds; LcdCalibrationView view = new LcdCalibrationView(device); view.Width = bounds.Width; view.Height = bounds.Height; var p = new Popup { Child = view, Margin = new Thickness(0), IsOpen = true }; try { return(await view.CalibrateAsync(style)); } finally { p.IsOpen = false; } }
public TouchPointWrapper(Point position, TouchAction action, int id) { _position = position; _action = action; _device = new TouchDeviceWrapper(id); }
public TouchProcessor(ITouchDevice device) { if (device == null) throw new ArgumentNullException(nameof(device)); this.device = device; }
/// <summary> /// Initialize a new <see cref="BasicTouchDeviceTracker"/> class. /// </summary> /// <param name="touchDevice"></param> public BasicTouchDeviceTracker(ITouchDevice touchDevice) : base(touchDevice) { }
public TouchProcessor(ITouchDevice touchDevice, CoreDispatcher dispatcher) { _touchDevice = touchDevice; _dispatcher = dispatcher; _penPressed = false; }