Browse Source

media player: remove no longer needed async calls

With v4, stop is asynchronous and runs on a background thread, so we no longer need to do it in VLCKit.
Felix Paul Kühne 5 years ago
parent
commit
1a12a2475e
2 changed files with 2 additions and 6 deletions
  1. 1 3
      Sources/VLCMediaListPlayer.m
  2. 1 3
      Sources/VLCMediaPlayer.m

+ 1 - 3
Sources/VLCMediaListPlayer.m

@@ -224,9 +224,7 @@ static void HandleMediaListPlayerStopped(const libvlc_event_t * event, void * se
 
 
 - (void)stop
 - (void)stop
 {
 {
-    dispatch_async(_libVLCBackgroundQueue, ^{
-        libvlc_media_list_player_stop_async(instance);
-    });
+    libvlc_media_list_player_stop_async(instance);
 }
 }
 
 
 - (BOOL)next
 - (BOOL)next

+ 1 - 3
Sources/VLCMediaPlayer.m

@@ -1043,9 +1043,7 @@ static void HandleMediaPlayerRecord(const libvlc_event_t * event, void * self)
 
 
 - (void)stop
 - (void)stop
 {
 {
-    dispatch_async(_libVLCBackgroundQueue, ^{
-        libvlc_media_player_stop_async(_playerInstance);
-    });
+    libvlc_media_player_stop_async(_playerInstance);
 }
 }
 
 
 - (libvlc_video_viewpoint_t *)viewPoint
 - (libvlc_video_viewpoint_t *)viewPoint