Explorar o código

playback controller: replace deprecated API call in VLCKit

This closes #143
Felix Paul Kühne %!s(int64=7) %!d(string=hai) anos
pai
achega
8db0d20b8a
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      Sources/VLCPlaybackController.m

+ 1 - 1
Sources/VLCPlaybackController.m

@@ -138,7 +138,7 @@ typedef NS_ENUM(NSUInteger, VLCAspectRatio) {
 
 - (void)openVideoSubTitlesFromFile:(NSString *)pathToFile
 {
-    [_mediaPlayer openVideoSubTitlesFromFile:pathToFile];
+    [_mediaPlayer addPlaybackSlave:[NSURL fileURLWithPath:pathToFile] type:VLCMediaPlaybackSlaveTypeSubtitle enforce:YES];
 }
 
 - (void)playMediaList:(VLCMediaList *)mediaList firstIndex:(NSInteger)index subtitlesFilePath:(NSString *)subsFilePath