Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>You can write the app to handle 2 UIScreens using Airplay and an Apple TV then set a seperate root view controller for both the TV UIScreen and for the iPad UIScreen. Then display the image or slideshow on the TV's view controller and run that from the events of you iPads view controller! </p> <p>AMENDED AFTER CLIFS COMMENT:</p> <p>So firstly in your app delegate in didFinishLaunchingWithOptions or didFinishLaunching setup a notification to receive the screen did connect.</p> <pre><code>[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(screenDidConnect:) name:UIScreenDidConnectNotification object:nil]; </code></pre> <p>Then you need to keep a reference to your separate window and push controllers to it as you would any other window.</p> <pre><code>- (void) myScreenInit:(UIScreen *)connectedScreen:(UIViewController*)mynewViewController { //Intitialise TV Screen if(!windowTV) { CGRect frame = connectedScreen.bounds; windowTV = [[UIWindow alloc] initWithFrame:frame]; windowTV.backgroundColor = [UIColor clearColor]; [windowTV setScreen:connectedScreen]; windowTV.hidden = NO; } UIViewController* release = windowTV.rootViewController; windowTV.rootViewController = mynewViewController; [release removeFromParentViewController]; [release release]; } - (void)setTvController:(UIViewController*)mynewViewController { UIViewController* release = windowTV.rootViewController; windowTV.rootViewController = mynewViewController; [release removeFromParentViewController]; [release release]; } - (void)screenDidConnect:(NSNotification *)notification { [self myScreenInit:[notification object]]; } </code></pre>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    3. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload