diff options
-rw-r--r-- | CyteKit/WebViewController.mm | 2 | ||||
-rw-r--r-- | MobileCydia.mm | 7 |
2 files changed, 8 insertions, 1 deletions
diff --git a/CyteKit/WebViewController.mm b/CyteKit/WebViewController.mm index 2d9cfe1..4b2116f 100644 --- a/CyteKit/WebViewController.mm +++ b/CyteKit/WebViewController.mm @@ -581,7 +581,7 @@ float CYScrollViewDecelerationRateNormal; // }}} - (void) close { - [[self navigationController] dismissModalViewControllerAnimated:YES]; + [[[self navigationController] parentViewController] dismissModalViewControllerAnimated:YES]; } - (void) alertView:(UIAlertView *)alert clickedButtonAtIndex:(NSInteger)button { diff --git a/MobileCydia.mm b/MobileCydia.mm index d6bea29..92f5a0a 100644 --- a/MobileCydia.mm +++ b/MobileCydia.mm @@ -6763,6 +6763,13 @@ bool DepSubstrate(const pkgCache::VerIterator &iterator) { return items; } +- (void) dismissModalViewControllerAnimated:(BOOL)animated { + if ([self modalViewController] == nil && [self unselectedViewController] != nil) + [self setUnselectedViewController:nil]; + else + [super dismissModalViewControllerAnimated:YES]; +} + - (void) unloadData { [super unloadData]; |