Last active
August 29, 2015 13:57
-
-
Save obyknovenius/9721868 to your computer and use it in GitHub Desktop.
Dismiss a Storyboard Popover
This file contains hidden or 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
@interface ViewController () | |
@property (nonatomic, strong) ReaderIssueView *issueView; | |
@end | |
- (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender | |
{ | |
self.thePopover = [(UIStoryboardPopoverSegue *)segue popoverController]; | |
} | |
- (BOOL)shouldPerformSegueWithIdentifier:(NSString *)identifier sender:(id)sender | |
{ | |
if (self.thePopover) { | |
[self.thePopover dismissPopoverAnimated:YES]; | |
return NO; | |
} else | |
return YES; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment