Commit b7f94731 authored by Romain Goyet's avatar Romain Goyet Committed by Felix Paul Kühne

Big cleansing of the menu dismissal behavior

Signed-off-by: Felix Paul Kühne's avatarFelix Paul Kühne <fkuehne@videolan.org>
parent 52f50740
......@@ -29,9 +29,6 @@
self.webView.delegate = self;
self.aspenVersion.text = [[NSString stringWithFormat:NSLocalizedString(@"VERSION_FORMAT",@""), [[NSBundle mainBundle] objectForInfoDictionaryKey:@"CFBundleVersion"]] stringByAppendingFormat:@" %@", kVLCVersionCodename];
self.vlckitVersion.text = [NSString stringWithFormat:NSLocalizedString(@"BASED_ON_FORMAT",@""),[[VLCLibrary sharedLibrary] version]];
if (UI_USER_INTERFACE_IDIOM() == UIUserInterfaceIdiomPad)
self.navigationItem.rightBarButtonItem = [UIBarButtonItem themedDoneButtonWithTarget:self andSelector:@selector(dismiss)];
}
- (BOOL)webView:(UIWebView *)webView shouldStartLoadWithRequest:(NSURLRequest *)request navigationType:(UIWebViewNavigationType)navigationType
......@@ -59,9 +56,4 @@
[UIView animateWithDuration:1. animations:animationBlock completion:completionBlock];
}
- (void)dismiss
{
[self dismissModalViewControllerAnimated:YES];
}
@end
......@@ -113,11 +113,6 @@
[_dropboxController requestDirectoryListingAtPath:_currentPath];
}
- (IBAction)dismiss:(id)sender
{
[self.navigationController dismissModalViewControllerAnimated:YES];
}
- (IBAction)folderUp:(id)sender
{
_currentPath = [_currentPath stringByDeletingLastPathComponent];
......
......@@ -23,5 +23,4 @@
- (IBAction)downloadAction:(id)sender;
- (IBAction)cancelDownload:(id)sender;
- (IBAction)dismiss:(id)sender;
@end
......@@ -71,11 +71,6 @@
}
}
- (IBAction)dismiss:(id)sender
{
[self.navigationController dismissModalViewControllerAnimated:YES];
}
#pragma mark - download management
- (void)_triggerNextDownload
{
......
......@@ -33,6 +33,7 @@
Reachability *_reachability;
}
- (void)_presentViewController:(UIViewController *)viewController;
- (void)_dismissModalViewController;
@end
@implementation VLCMenuViewController
......@@ -204,11 +205,16 @@
[self presentModalViewController:navController animated:YES];
if (viewController.navigationItem.rightBarButtonItem == nil) {
UIBarButtonItem *doneButton = [UIBarButtonItem themedDoneButtonWithTarget:viewController andSelector:@selector(dismiss:)];
UIBarButtonItem *doneButton = [UIBarButtonItem themedDoneButtonWithTarget:self andSelector:@selector(_dismissModalViewController)];
viewController.navigationItem.rightBarButtonItem = doneButton;
}
} else {
[self.navigationController pushViewController:viewController animated:YES];
}
}
- (void)_dismissModalViewController
{
[self dismissModalViewControllerAnimated:YES];
}
@end
......@@ -17,6 +17,5 @@
@property (strong, nonatomic) IBOutlet UITableView *historyTableView;
- (IBAction)openButtonAction:(id)sender;
- (IBAction)dismiss:(id)sender;
@end
......@@ -80,11 +80,6 @@
}
}
- (IBAction)dismiss:(id)sender
{
[self.navigationController dismissModalViewControllerAnimated:YES];
}
#pragma mark - table view data source
- (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView
{
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment