mirror of
https://github.com/libsdl-org/SDL.git
synced 2026-05-03 23:00:14 +02:00
Add SDL_IsTV() (#11004)
Moved SDL_IsAndroidTV() out of public API, to match SDL_IsAndroidTablet(). Added SDL_IsTV(), to mirror existing SDL_IsTablet().
This commit is contained in:
@@ -297,7 +297,7 @@ void SDL_NSLog(const char *prefix, const char *text)
|
||||
#endif // SDL_VIDEO_DRIVER_COCOA
|
||||
|
||||
/*
|
||||
* iOS Tablet detection
|
||||
* iOS Tablet, etc, detection
|
||||
*
|
||||
* This doesn't really have anything to do with the interfaces of the SDL video
|
||||
* subsystem, but we need to stuff this into an Objective-C source code file.
|
||||
@@ -307,4 +307,9 @@ bool SDL_IsIPad(void)
|
||||
return ([UIDevice currentDevice].userInterfaceIdiom == UIUserInterfaceIdiomPad);
|
||||
}
|
||||
|
||||
bool SDL_IsAppleTV(void)
|
||||
{
|
||||
return ([UIDevice currentDevice].userInterfaceIdiom == UIUserInterfaceIdiomTV);
|
||||
}
|
||||
|
||||
#endif // SDL_VIDEO_DRIVER_UIKIT
|
||||
|
||||
Reference in New Issue
Block a user