Created
October 8, 2012 17:29
-
-
Save swarut/3853767 to your computer and use it in GitHub Desktop.
Objective-C : Custom non-animated segue #objective-c #segue #customsegue
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@implementation NonAnimatedSegue | |
- (id) initWithIdentifier:(NSString *)identifier source:(UIViewController *)source destination:(UIViewController *)destination{ | |
self = [super initWithIdentifier:identifier source:source destination:destination]; | |
if(self){ | |
} | |
return self; | |
} | |
- (void) perform{ | |
[[[self sourceViewController] navigationController] pushViewController:[self destinationViewController] animated:NO]; | |
// This doesn't work | |
// [[self sourceViewController] presentViewController:[self destinationViewController] | |
// animated:NO completion:nil]; | |
} | |
@end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment