|
@@ -99,6 +99,9 @@
|
|
|
#ifndef WM_GETDPISCALEDSIZE
|
|
|
#define WM_GETDPISCALEDSIZE 0x02E4
|
|
|
#endif
|
|
|
+#ifndef TOUCHEVENTF_PEN
|
|
|
+#define TOUCHEVENTF_PEN 0x0040
|
|
|
+#endif
|
|
|
|
|
|
#ifndef IS_HIGH_SURROGATE
|
|
|
#define IS_HIGH_SURROGATE(x) (((x) >= 0xd800) && ((x) <= 0xdbff))
|
|
@@ -1396,7 +1399,7 @@ WIN_WindowProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam)
|
|
|
/* TODO: Can we use GetRawInputDeviceInfo and HID info to
|
|
|
determine if this is a direct or indirect touch device?
|
|
|
*/
|
|
|
- if (SDL_AddTouch(touchId, SDL_TOUCH_DEVICE_DIRECT, "") < 0) {
|
|
|
+ if (SDL_AddTouch(touchId, SDL_TOUCH_DEVICE_DIRECT, (input->dwFlags & TOUCHEVENTF_PEN) == TOUCHEVENTF_PEN ? "pen" : "touch") < 0) {
|
|
|
continue;
|
|
|
}
|
|
|
|