拦截指针事件是UWP应用程序

时间:2017-08-02 10:46:13

标签: c# uwp

我有一个5英寸的显示屏,想在windows iot core中进行校准 LCD触摸工作,但没有正确校准,换句话说,当在屏幕上触摸一个点时,点的X,Y在申请表上没有真正对齐。

我有校准算法,但我想要一个解决方案,通常在我的应用程序中处理这个,如:

Window.Current.CoreWindow.PointerPressed += CoreWindow_PointerPressed;

    private void CoreWindow_PointerPressed(Windows.UI.Core.CoreWindow sender, Windows.UI.Core.PointerEventArgs args)
    {
        Point touchedPoint = args.CurrentPoint.Position;        //get the current touched point
        Point calibratedPoint = Calibrate(touchedPoint);        //run the calibration algorithm on the point and get new point

        //raise new calibratedPoint (as a Pointer pressed) to the application window
    }

如何将新的校准点提升到应用程序窗口?

0 个答案:

没有答案