Commit 1526379a authored by Felix Paul Kühne's avatar Felix Paul Kühne

library: disable folder button in TV show and music album mode (closes #14733)

parent 0223df2a
......@@ -523,6 +523,7 @@ static NSString *kUsingTableViewToShowData = @"UsingTableViewToShowData";
}
self.navigationItem.leftBarButtonItem = _menuButton;
if (_libraryMode == VLCLibraryModeAllAlbums)
self.title = NSLocalizedString(@"LIBRARY_MUSIC", nil);
else if( _libraryMode == VLCLibraryModeAllSeries)
......@@ -530,6 +531,14 @@ static NSString *kUsingTableViewToShowData = @"UsingTableViewToShowData";
else
self.title = NSLocalizedString(@"LIBRARY_ALL_FILES", nil);
NSMutableArray *toolbarItems = [self.toolbarItems mutableCopy];
if (toolbarItems.count >= 3) {
UIBarButtonItem *createFolderButton = toolbarItems[2];
createFolderButton.enabled = (_libraryMode == VLCLibraryModeAllAlbums || _libraryMode == VLCLibraryModeAllSeries) ? NO : YES;
toolbarItems[2] = createFolderButton;
self.toolbarItems = toolbarItems;
}
/* add all albums */
if (_libraryMode != VLCLibraryModeAllSeries) {
NSArray *rawAlbums = [MLAlbum allAlbums];
......
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