comparison src/video/win32/SDL_win32video.h @ 4919:716b2cbf4c9e

First pass at Windows multi-touch gesture support
author Sam Lantinga <slouken@libsdl.org>
date Tue, 30 Nov 2010 17:58:51 -0800
parents 37576cdf6751
children 40ef2ad3757c
comparison
equal deleted inserted replaced
4918:f5f70fed2c4c 4919:716b2cbf4c9e
77 #define WIN_UTF8ToString(S) SDL_iconv_string("ASCII", "UTF-8", (char *)S, SDL_strlen(S)+1) 77 #define WIN_UTF8ToString(S) SDL_iconv_string("ASCII", "UTF-8", (char *)S, SDL_strlen(S)+1)
78 #endif 78 #endif
79 extern void WIN_SetError(const char *prefix); 79 extern void WIN_SetError(const char *prefix);
80 80
81 enum { RENDER_NONE, RENDER_D3D, RENDER_DDRAW, RENDER_GDI, RENDER_GAPI, RENDER_RAW }; 81 enum { RENDER_NONE, RENDER_D3D, RENDER_DDRAW, RENDER_GDI, RENDER_GAPI, RENDER_RAW };
82
83 #if WINVER < 0x0601
84 /* Touch input definitions */
85 #define TWF_FINETOUCH 1
86 #define TWF_WANTPALM 2
87
88 #define TOUCHEVENTF_MOVE 0x0001
89 #define TOUCHEVENTF_DOWN 0x0002
90 #define TOUCHEVENTF_UP 0x0004
91
92 DECLARE_HANDLE(HTOUCHINPUT);
93
94 typedef struct _TOUCHINPUT {
95 LONG x;
96 LONG y;
97 HANDLE hSource;
98 DWORD dwID;
99 DWORD dwFlags;
100 DWORD dwMask;
101 DWORD dwTime;
102 ULONG_PTR dwExtraInfo;
103 DWORD cxContact;
104 DWORD cyContact;
105 } TOUCHINPUT, *PTOUCHINPUT;
106
107 #endif /* WINVER < 0x0601 */
82 108
83 typedef BOOL (*PFNSHFullScreen)(HWND, DWORD); 109 typedef BOOL (*PFNSHFullScreen)(HWND, DWORD);
84 typedef void (*PFCoordTransform)(SDL_Window*, POINT*); 110 typedef void (*PFCoordTransform)(SDL_Window*, POINT*);
85 111
86 typedef struct 112 typedef struct
133 PFNSHFullScreen SHFullScreen; 159 PFNSHFullScreen SHFullScreen;
134 PFCoordTransform CoordTransform; 160 PFCoordTransform CoordTransform;
135 #endif 161 #endif
136 162
137 const SDL_scancode *key_layout; 163 const SDL_scancode *key_layout;
138 DWORD clipboard_count; 164 DWORD clipboard_count;
165
166 /* Touch input functions */
167 HANDLE userDLL;
168 BOOL (WINAPI *CloseTouchInputHandle)( HTOUCHINPUT );
169 BOOL (WINAPI *GetTouchInputInfo)( HTOUCHINPUT, UINT, PTOUCHINPUT, int );
170 BOOL (WINAPI *RegisterTouchWindow)( HWND, ULONG );
139 171
140 SDL_bool ime_com_initialized; 172 SDL_bool ime_com_initialized;
141 struct ITfThreadMgr *ime_threadmgr; 173 struct ITfThreadMgr *ime_threadmgr;
142 SDL_bool ime_initialized; 174 SDL_bool ime_initialized;
143 SDL_bool ime_enabled; 175 SDL_bool ime_enabled;