From eb19bd06d27455b93f38b5d281324d66b4873731 Mon Sep 17 00:00:00 2001 From: "Ryan C. Gordon" Date: Sat, 19 Nov 2011 19:18:20 -0500 Subject: [PATCH] Check for selectors UIScreen responds to, not the base system version. Thanks to Vittorio Giovara for the patch! --- src/video/uikit/SDL_uikitvideo.m | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/video/uikit/SDL_uikitvideo.m b/src/video/uikit/SDL_uikitvideo.m index 658aa3dcb..354e35fb4 100644 --- a/src/video/uikit/SDL_uikitvideo.m +++ b/src/video/uikit/SDL_uikitvideo.m @@ -201,10 +201,8 @@ UIKit_VideoInit(_THIS) { _this->gl_config.driver_loaded = 1; - NSString *reqSysVer = @"3.2"; - NSString *currSysVer = [[UIDevice currentDevice] systemVersion]; - if ([currSysVer compare:reqSysVer options:NSNumericSearch] != NSOrderedAscending) - SDL_UIKit_supports_multiple_displays = YES; + // this tells us whether we are running on ios >= 3.2 + SDL_UIKit_supports_multiple_displays = [UIScreen instancesRespondToSelector:@selector(currentMode)]; // Add the main screen. UIScreen *uiscreen = [UIScreen mainScreen];