Implement pointer input APIs for multi-touch support
These patches implemeted core pointer input APIs required by modern applications with touchscreen support, particularly Chromium and Qt-based applications.
Implemented APIs:
- GetPointerType: Query pointer input type (touch, pen, mouse)
- GetPointerTouchInfo: Retrieve detailed touch pointer information
- GetPointerFrameTouchInfo: Get all active touch pointers in current frame
Added stubs:
- SkipPointerFrameMessages: Used by applications to skip pointer frame processing like Qt
- GetPointerFrameTouchInfoHistory: Historical touch frame data (not yet implemented)
- GetPointerPenInfoHistory: Historical pen data (not yet implemented)
System metrics changes:
- SM_DIGITIZER: Reports touch capabilities (NID_INTEGRATED_TOUCH | NID_MULTI_INPUT | NID_READY)
- SM_MAXIMUMTOUCHES: Returns maximum simultaneous touch points (10)
Limitations:
- We explictly set pointer type to PT_TOUCH when storing pointer info to queue, so GetPointerType will always return PT_TOUCH
- GetPointerFrameTouchInfo returns 0 pointers after finger lift, while Windows returns 1 pointer with UP flags. And SkipPointerFrameMessages is currently a stub returning TRUE. Qt's pointer message processing uses both of them, but it's just working well
Application requirements:
- Chromium: Requires GetPointerType and GetPointerTouchInfo for touch input
- Qt applications: Need GetPointerFrameTouchInfo and proper system metrics for multi-touch support
- Qt5: Additionally checks for presence of all pointer APIs at runtime, requiring stubs to enable pointer messages processing
Edited by Hecheng Yu