summaryrefslogtreecommitdiff
path: root/CyteKit/WebViewController.mm
diff options
context:
space:
mode:
Diffstat (limited to 'CyteKit/WebViewController.mm')
-rw-r--r--CyteKit/WebViewController.mm4
1 files changed, 2 insertions, 2 deletions
diff --git a/CyteKit/WebViewController.mm b/CyteKit/WebViewController.mm
index 25e9aeb..cfe01f7 100644
--- a/CyteKit/WebViewController.mm
+++ b/CyteKit/WebViewController.mm
@@ -630,7 +630,7 @@ float CYScrollViewDecelerationRateNormal;
// }}}
- (void) close {
- [[[self navigationController] parentViewController] dismissModalViewControllerAnimated:YES];
+ [[[self navigationController] parentOrPresentingViewController] dismissModalViewControllerAnimated:YES];
}
- (void) alertView:(UIAlertView *)alert clickedButtonAtIndex:(NSInteger)button {
@@ -714,7 +714,7 @@ float CYScrollViewDecelerationRateNormal;
return nil;
if (UINavigationController *navigation = [self navigationController])
- if ([[navigation parentViewController] modalViewController] == navigation)
+ if ([[navigation parentOrPresentingViewController] modalViewController] == navigation)
return [[[UIBarButtonItem alloc]
initWithTitle:UCLocalize("CLOSE")
style:UIBarButtonItemStylePlain