include/SDL_touch.h
changeset 12404 eb60e952b13f
parent 11811 5d94cb6b24d3
child 12432 defbd51902c3
     1.1 --- a/include/SDL_touch.h	Wed Nov 07 07:52:39 2018 -0800
     1.2 +++ b/include/SDL_touch.h	Sat Nov 10 16:15:48 2018 -0400
     1.3 @@ -41,6 +41,14 @@
     1.4  typedef Sint64 SDL_TouchID;
     1.5  typedef Sint64 SDL_FingerID;
     1.6  
     1.7 +typedef enum
     1.8 +{
     1.9 +    SDL_TOUCH_DEVICE_INVALID = -1,
    1.10 +    SDL_TOUCH_DEVICE_DIRECT,            /* touch screen with window-relative coordinates */
    1.11 +    SDL_TOUCH_DEVICE_INDIRECT_ABSOLUTE, /* trackpad with absolute device coordinates */
    1.12 +    SDL_TOUCH_DEVICE_INDIRECT_RELATIVE, /* trackpad with screen cursor-relative coordinates */
    1.13 +} SDL_TouchDeviceType;
    1.14 +
    1.15  typedef struct SDL_Finger
    1.16  {
    1.17      SDL_FingerID id;
    1.18 @@ -66,6 +74,11 @@
    1.19  extern DECLSPEC SDL_TouchID SDLCALL SDL_GetTouchDevice(int index);
    1.20  
    1.21  /**
    1.22 + * \brief Get the type of the given touch device.
    1.23 + */
    1.24 +extern DECLSPEC SDL_TouchDeviceType SDLCALL SDL_GetTouchDeviceType(SDL_TouchID touchID);
    1.25 +
    1.26 +/**
    1.27   *  \brief Get the number of active fingers for a given touch device.
    1.28   */
    1.29  extern DECLSPEC int SDLCALL SDL_GetNumTouchFingers(SDL_TouchID touchID);