Browse Source

player: signal on_current_media_stopping event

Signal that the media is stopping to the client. This is done after
input_Stop so that application can rely on the fact that the underlying
input_thread is already stopping, so that we can trigger actions like
EOS, closing input resources, etc.
pull/162/head
Alexandre Janniaux 3 years ago
committed by Steve Lhomme
parent
commit
e651ac80f1
  1. 5
      src/player/player.c

5
src/player/player.c

@ -223,7 +223,12 @@ vlc_player_destructor_Thread(void *data)
VLC_TICK_INVALID);
vlc_player_destructor_AddStoppingInput(player, input);
/* Note: no need to hold the media here, it will be valid
* until input_Close() and the event is sent from the thread
* that will call this function. */
input_item_t *media = input_GetItem(input->thread);
input_Stop(input->thread);
vlc_player_SendEvent(player, on_stopping_current_media, media);
}
bool keep_sout = true;

Loading…
Cancel
Save