Go Back   MacRumors Forums > Apple Systems and Services > Programming > iPhone/iPad Programming

Reply
 
Thread Tools Search this Thread Display Modes
Old Aug 4, 2012, 04:44 AM   #1
nashyo
macrumors 6502
 
Join Date: Oct 2010
Location: Bristol
Custom Segue

I'm trying to set up a custom segue, but I am getting a strange error message.

I have two scenes connected in storyboard with 'custom' connection. I have subclassed UIStoryboard segue and I have input the class name and segue identifier into storyboard.

The first scene is a tableview and it's delegate calls performseguewithidentifier.

UIStoryboardSegue Subclass
Code:
-(void)perform
{
    __block UIViewController *sourceViewController = (UIViewController*) [self sourceViewController];
    __block UIViewController *destinationViewController = (UIViewController*) [self destinationViewController];
    
    [UIView transitionWithView:sourceViewController.navigationController.view
                      duration:.5
                       options:UIViewAnimationOptionTransitionFlipFromBottom
                    animations:^{
                        [sourceViewController.navigationController presentModalViewController:destinationViewController animated:NO];
                    }
                    completion:^(BOOL finished) {
                        NSLog(@"Transition Completed");
                    }];
}
Error
"Application tried to present modally an active controller"

What does this mean? And why hasn't it worked?

Thanks
__________________
Xcode 4.5.2, SDK 6.0, OSX Mountain Lion, ARC
nashyo is offline   0 Reply With Quote

Reply
MacRumors Forums > Apple Systems and Services > Programming > iPhone/iPad Programming

Tags
custom, segue

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Similar Threads
thread Thread Starter Forum Replies Last Post
A one way segue? whitedragon101 iPhone/iPad Programming 1 Apr 8, 2014 03:56 AM
Resolved: UIAlertView Unwind Segue Blakeasd iPhone/iPad Programming 8 Mar 21, 2014 03:04 PM
segue Hustle iPhone/iPad Programming 6 Jun 26, 2013 11:07 PM
Passing Data Between Segue w3tmb iPhone/iPad Programming 1 Feb 10, 2013 01:57 PM
Popover segue documentation/tutorial? whooleytoo iPhone/iPad Programming 5 Jun 9, 2012 08:07 AM

Forum Jump

All times are GMT -5. The time now is 07:22 PM.

Mac Rumors | Mac | iPhone | iPhone Game Reviews | iPhone Apps

Mobile Version | Fixed | Fluid | Fluid HD
Copyright 2002-2013, MacRumors.com, LLC