Commit ef84c9c9 authored by Igor Prokopenkov's avatar Igor Prokopenkov Committed by Felix Paul Kühne

lib: Fire libvlc_MediaListPlayerPlayed at end of playlist

The "libvlc_MediaListPlayerPlayed" event was defined but unused.
It is now fired when libvlc_media_list_player is played until last item in the playlist
Signed-off-by: default avatarIgor Prokopenkov <cmyk777@gmail.com>
Signed-off-by: default avatarJean-Baptiste Kempf <jb@videolan.org>
(cherry picked from commit fd4a0ba83493bd91f2adb7b68ae9fb3c3d5fc972)
Signed-off-by: default avatarFelix Paul Kühne <fkuehne@videolan.org>
parent cd4d3a09
......@@ -474,6 +474,8 @@ libvlc_media_list_player_new(libvlc_instance_t * p_instance)
libvlc_MediaListPlayerNextItemSet );
libvlc_event_manager_register_event_type( p_mlp->p_event_manager,
libvlc_MediaListPlayerStopped );
libvlc_event_manager_register_event_type( p_mlp->p_event_manager,
libvlc_MediaListPlayerPlayed );
p_mlp->e_playback_mode = libvlc_playback_mode_default;
return p_mlp;
......@@ -781,6 +783,10 @@ static int set_relative_playlist_position_and_play(
if (!path)
{
libvlc_media_list_unlock(p_mlp->p_mlist);
/* Send list played event */
libvlc_event_t event;
event.type = libvlc_MediaListPlayerPlayed;
libvlc_event_send(p_mlp->p_event_manager, &event);
return -1;
}
......
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