src/video/uikit/SDL_uikitappdelegate.m
changeset 10340 5724f5087acd
parent 10048 b86bef2d4f30
child 10350 130fc0b68ca8
     1.1 --- a/src/video/uikit/SDL_uikitappdelegate.m	Tue Sep 13 19:51:10 2016 -0300
     1.2 +++ b/src/video/uikit/SDL_uikitappdelegate.m	Tue Sep 13 22:18:06 2016 -0300
     1.3 @@ -76,6 +76,7 @@
     1.4      [UIApplication sharedApplication].idleTimerDisabled = disable;
     1.5  }
     1.6  
     1.7 +#if !TARGET_OS_TV
     1.8  /* Load a launch image using the old UILaunchImageFile-era naming rules. */
     1.9  static UIImage *
    1.10  SDL_LoadLaunchImageNamed(NSString *name, int screenh)
    1.11 @@ -114,6 +115,15 @@
    1.12  
    1.13      return image;
    1.14  }
    1.15 +#endif /* !TARGET_OS_TV */
    1.16 +
    1.17 +@interface SDLLaunchScreenController ()
    1.18 +
    1.19 +#if !TARGET_OS_TV
    1.20 +- (NSUInteger)supportedInterfaceOrientations;
    1.21 +#endif
    1.22 +
    1.23 +@end
    1.24  
    1.25  @implementation SDLLaunchScreenController
    1.26  
    1.27 @@ -140,6 +150,7 @@
    1.28      }
    1.29  
    1.30      if (!self.view) {
    1.31 +#if !TARGET_OS_TV
    1.32          NSArray *launchimages = [bundle objectForInfoDictionaryKey:@"UILaunchImages"];
    1.33          UIInterfaceOrientation curorient = [UIApplication sharedApplication].statusBarOrientation;
    1.34          NSString *imagename = nil;
    1.35 @@ -244,6 +255,9 @@
    1.36  
    1.37              self.view = view;
    1.38          }
    1.39 +#else /* !TARGET_OS_TV */
    1.40 +        return nil;
    1.41 +#endif
    1.42      }
    1.43  
    1.44      return self;
    1.45 @@ -254,6 +268,7 @@
    1.46      /* Do nothing. */
    1.47  }
    1.48  
    1.49 +#if !TARGET_OS_TV
    1.50  - (BOOL)shouldAutorotate
    1.51  {
    1.52      /* If YES, the launch image will be incorrectly rotated in some cases. */
    1.53 @@ -267,6 +282,7 @@
    1.54       * the ones set here (it will cause an exception in that case.) */
    1.55      return UIInterfaceOrientationMaskAll;
    1.56  }
    1.57 +#endif /* !TARGET_OS_TV */
    1.58  
    1.59  @end
    1.60  
    1.61 @@ -381,6 +397,7 @@
    1.62      SDL_SendAppEvent(SDL_APP_LOWMEMORY);
    1.63  }
    1.64  
    1.65 +#if !TARGET_OS_TV
    1.66  - (void)application:(UIApplication *)application didChangeStatusBarOrientation:(UIInterfaceOrientation)oldStatusBarOrientation
    1.67  {
    1.68      BOOL isLandscape = UIInterfaceOrientationIsLandscape(application.statusBarOrientation);
    1.69 @@ -408,6 +425,7 @@
    1.70          }
    1.71      }
    1.72  }
    1.73 +#endif
    1.74  
    1.75  - (void)applicationWillResignActive:(UIApplication*)application
    1.76  {