Pārlūkot izejas kodu

library: sort TV shows by Season / Episode number and music albums by track number (close #10144)

Felix Paul Kühne 11 gadi atpakaļ
vecāks
revīzija
b6c0d46e0c
3 mainītis faili ar 5 papildinājumiem un 3 dzēšanām
  1. 2 0
      NEWS
  2. 2 2
      Sources/VLCPlaylistViewController.m
  3. 1 1
      compileVLCforiOS.sh

+ 2 - 0
NEWS

@@ -23,6 +23,8 @@ Interface:
   app and by obfuscating playback metadata if passcode lock is enabled
 * Added support to endlessly repeat the currently playing item (#9793)
 * Added option to disable file name display optimizations (#10050)
+* TV Shows are sorted by Season number / Episode number and Music Albums
+  respectively by track number
 
 Cloud interaction:
 * Added support for downloads from Google Drive (#8690)

+ 2 - 2
Sources/VLCPlaylistViewController.m

@@ -170,7 +170,7 @@
 - (void)openMediaObject:(NSManagedObject *)mediaObject
 {
     if ([mediaObject isKindOfClass:[MLAlbum class]]) {
-        _foundMedia = [NSMutableArray arrayWithArray:[[(MLAlbum *)mediaObject tracks] allObjects]];
+        _foundMedia = [NSMutableArray arrayWithArray:[(MLAlbum *)mediaObject sortedTracks]];
         self.navigationItem.leftBarButtonItem = [UIBarButtonItem themedBackButtonWithTarget:self andSelector:@selector(backToAllItems:)];
         if (_libraryMode == VLCLibraryModeAllFiles)
             self.navigationItem.leftBarButtonItem.title = NSLocalizedString(@"BUTTON_BACK", @"");
@@ -179,7 +179,7 @@
         self.title = [(MLAlbum*)mediaObject name];
         [self reloadViews];
     } else if ([mediaObject isKindOfClass:[MLShow class]]) {
-        _foundMedia = [NSMutableArray arrayWithArray:[[(MLShow *)mediaObject episodes] allObjects]];
+        _foundMedia = [NSMutableArray arrayWithArray:[(MLShow *)mediaObject sortedEpisodes]];
         self.navigationItem.leftBarButtonItem = [UIBarButtonItem themedBackButtonWithTarget:self andSelector:@selector(backToAllItems:)];
         if (_libraryMode == VLCLibraryModeAllFiles)
             self.navigationItem.leftBarButtonItem.title = NSLocalizedString(@"BUTTON_BACK", @"");

+ 1 - 1
compileVLCforiOS.sh

@@ -13,7 +13,7 @@ NONETWORK=no
 SKIPLIBVLCCOMPILATION=no
 
 TESTEDVLCKITHASH=d0e7b32b4
-TESTEDMEDIALIBRARYKITHASH=aad52e7e6
+TESTEDMEDIALIBRARYKITHASH=ff386534b
 
 usage()
 {