Made SDL_GetAndroidSDKVersion() available for applications
authorSam Lantinga
Mon, 17 Feb 2020 13:54:45 -0800
changeset 1353797d093e10ac7
parent 13536 4ba421b1e88f
child 13538 2478e1898463
Made SDL_GetAndroidSDKVersion() available for applications
include/SDL_system.h
src/dynapi/SDL_dynapi_overrides.h
src/dynapi/SDL_dynapi_procs.h
     1.1 --- a/include/SDL_system.h	Mon Feb 17 16:15:04 2020 -0500
     1.2 +++ b/include/SDL_system.h	Mon Feb 17 13:54:45 2020 -0800
     1.3 @@ -121,6 +121,32 @@
     1.4  extern DECLSPEC void * SDLCALL SDL_AndroidGetActivity(void);
     1.5  
     1.6  /**
     1.7 +   \brief Return API level of the current device
     1.8 +
     1.9 +    API level 29: Android 10
    1.10 +    API level 28: Android 9
    1.11 +    API level 27: Android 8.1
    1.12 +    API level 26: Android 8.0
    1.13 +    API level 25: Android 7.1
    1.14 +    API level 24: Android 7.0
    1.15 +    API level 23: Android 6.0
    1.16 +    API level 22: Android 5.1
    1.17 +    API level 21: Android 5.0
    1.18 +    API level 20: Android 4.4W
    1.19 +    API level 19: Android 4.4
    1.20 +    API level 18: Android 4.3
    1.21 +    API level 17: Android 4.2
    1.22 +    API level 16: Android 4.1
    1.23 +    API level 15: Android 4.0.3
    1.24 +    API level 14: Android 4.0
    1.25 +    API level 13: Android 3.2
    1.26 +    API level 12: Android 3.1
    1.27 +    API level 11: Android 3.0
    1.28 +    API level 10: Android 2.3.3
    1.29 + */
    1.30 +extern DECLSPEC int SDLCALL SDL_GetAndroidSDKVersion(void);
    1.31 +
    1.32 +/**
    1.33     \brief Return true if the application is running on Android TV
    1.34   */
    1.35  extern DECLSPEC SDL_bool SDLCALL SDL_IsAndroidTV(void);
     2.1 --- a/src/dynapi/SDL_dynapi_overrides.h	Mon Feb 17 16:15:04 2020 -0500
     2.2 +++ b/src/dynapi/SDL_dynapi_overrides.h	Mon Feb 17 13:54:45 2020 -0800
     2.3 @@ -746,3 +746,4 @@
     2.4  #define SDL_OnApplicationWillEnterForeground SDL_OnApplicationWillEnterForeground_REAL
     2.5  #define SDL_OnApplicationDidBecomeActive SDL_OnApplicationDidBecomeActive_REAL
     2.6  #define SDL_OnApplicationDidChangeStatusBarOrientation SDL_OnApplicationDidChangeStatusBarOrientation_REAL
     2.7 +#define SDL_GetAndroidSDKVersion SDL_GetAndroidSDKVersion_REAL
     3.1 --- a/src/dynapi/SDL_dynapi_procs.h	Mon Feb 17 16:15:04 2020 -0500
     3.2 +++ b/src/dynapi/SDL_dynapi_procs.h	Mon Feb 17 13:54:45 2020 -0800
     3.3 @@ -804,3 +804,4 @@
     3.4  #ifdef __IPHONEOS__
     3.5  SDL_DYNAPI_PROC(void,SDL_OnApplicationDidChangeStatusBarOrientation,(void),(),)
     3.6  #endif
     3.7 +SDL_DYNAPI_PROC(int,SDL_GetAndroidSDKVersion,(void),(),return)