Commits

Marcus von Appen  committed 4d0296d

Added new SDL2 Android syswm information

  • Participants
  • Parent commits 5ef8e9f

Comments (0)

Files changed (1)

File sdl2/syswm.py

 __all__ = ["SDL_SYSWM_TYPE", "SDL_SYSWM_UNKNOWN", "SDL_SYSWM_WINDOWS",
            "SDL_SYSWM_X11", "SDL_SYSWM_DIRECTFB", "SDL_SYSWM_COCOA",
            "SDL_SYSWM_UIKIT", "SDL_SYSWM_WAYLAND", "SDL_SYSWM_MIR",
-           "SDL_SYSWM_WINRT",
+           "SDL_SYSWM_WINRT", "SDL_SYSWM_ANDROID",
            "SDL_SysWMmsg", "SDL_SysWMinfo", "SDL_GetWindowWMInfo"
            ]
 
 SDL_SYSWM_WAYLAND = 6
 SDL_SYSWM_MIR = 7
 SDL_SYSWM_WINRT = 8
+SDL_SYSWM_ANDROID = 9
 
 # FIXME: Hack around the ctypes "_type_ 'v' not supported" bug - remove
 # once this has been fixed properly in Python 2.7+
                 ("surface", c_void_p)]
 
 
+class _android(Structure):
+    """Window information for Android."""
+    _fields_ = [("window", c_void_p),
+                ("surface", c_void_p)]
+
+
 class _info(Union):
     """The platform-specific information of a window."""
     _fields_ = [("win", _wininfo),
                 ("uikit", _uikitinfo),
                 ("wl", _wl),
                 ("mir", _mir),
+                ("android", _android),
                 ("dummy", c_int)
                 ]