Commit abe2f681 authored by Felix Paul Kühne's avatar Felix Paul Kühne

Deploy kVLCAutomaticallyPlayNextItem for local files

parent 710ec55a
......@@ -82,6 +82,12 @@ Open a file in the libraryViewController without changing the playstate
- (void)configureWithShowEpisode:(MLShowEpisode *)showEpisode
{
NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults];
if (![defaults boolForKey:kVLCAutomaticallyPlayNextItem]) {
[self playMediaLibraryObject:showEpisode.files.anyObject];
return;
}
NSArray *episodes = [[showEpisode show] sortedEpisodes];
NSMutableArray *files = [NSMutableArray arrayWithCapacity:episodes.count];
for (MLShowEpisode *episode in episodes) {
......@@ -95,6 +101,12 @@ Open a file in the libraryViewController without changing the playstate
- (void)configureWithAlbumTrack:(MLAlbumTrack *)albumTrack
{
NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults];
if (![defaults boolForKey:kVLCAutomaticallyPlayNextItem]) {
[self playMediaLibraryObject:albumTrack.anyFileFromTrack];
return;
}
NSArray *tracks = [[albumTrack album] sortedTracks];
NSMutableArray *files = [NSMutableArray arrayWithCapacity:tracks.count];
for (MLAlbumTrack *track in tracks) {
......
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