12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485 |
- From 98b46970488758b32361f7f7a6581d0930927da4 Mon Sep 17 00:00:00 2001
- From: =?UTF-8?q?Felix=20Paul=20K=C3=BChne?= <fkuehne@videolan.org>
- Date: Thu, 10 Sep 2015 13:43:36 +0200
- Subject: [PATCH 11/13] libvlc media list player: add getter player instance
- ---
- include/vlc/libvlc_media_list_player.h | 10 ++++++++++
- lib/libvlc.sym | 1 +
- lib/media_list_player.c | 16 +++++++++++++++-
- 3 files changed, 26 insertions(+), 1 deletion(-)
- diff --git a/include/vlc/libvlc_media_list_player.h b/include/vlc/libvlc_media_list_player.h
- index b85981d..71e2ac0 100644
- --- a/include/vlc/libvlc_media_list_player.h
- +++ b/include/vlc/libvlc_media_list_player.h
- @@ -103,6 +103,16 @@ LIBVLC_API void
- libvlc_media_player_t * p_mi );
-
- /**
- + * Get media player instance in this media_list_player instance.
- + *
- + * \param p_mlp media list player instance
- + * \return p_mi media player instance
- + * \note the caller is responsible for releasing the player instance
- + */
- +LIBVLC_API libvlc_media_player_t *
- + libvlc_media_list_player_get_media_player(libvlc_media_list_player_t * p_mlp);
- +
- +/**
- * Set the media list associated with the player
- *
- * \param p_mlp media list player instance
- diff --git a/lib/libvlc.sym b/lib/libvlc.sym
- index 06c9826..97b153b 100644
- --- a/lib/libvlc.sym
- +++ b/lib/libvlc.sym
- @@ -109,6 +109,7 @@ libvlc_media_list_lock
- libvlc_media_list_media
- libvlc_media_list_new
- libvlc_media_list_player_event_manager
- +libvlc_media_list_player_get_media_player
- libvlc_media_list_player_get_state
- libvlc_media_list_player_is_playing
- libvlc_media_list_player_new
- diff --git a/lib/media_list_player.c b/lib/media_list_player.c
- index 44f75a0..b5a645e 100644
- --- a/lib/media_list_player.c
- +++ b/lib/media_list_player.c
- @@ -1,10 +1,12 @@
- /*****************************************************************************
- * media_list_player.c: libvlc new API media_list player functions
- *****************************************************************************
- - * Copyright (C) 2007 VLC authors and VideoLAN
- + * Copyright (C) 2007-2015 VLC authors and VideoLAN
- * $Id$
- *
- * Authors: Pierre d'Herbemont <pdherbemont # videolan.org>
- + * Niles Bindel <zaggal69 # gmail.com>
- + * Rémi Denis-Courmont
- *
- * This program is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as published by
- @@ -601,6 +603,18 @@ void libvlc_media_list_player_set_media_player(libvlc_media_list_player_t * p_ml
- }
-
- /**************************************************************************
- + * get_media_player (Public)
- + **************************************************************************/
- +libvlc_media_player_t * libvlc_media_list_player_get_media_player(libvlc_media_list_player_t * p_mlp)
- +{
- + if (p_mlp->p_mi == NULL)
- + return NULL;
- +
- + libvlc_media_player_retain(p_mlp->p_mi);
- + return p_mlp->p_mi;
- +}
- +
- +/**************************************************************************
- * set_media_list (Public)
- **************************************************************************/
- void libvlc_media_list_player_set_media_list(libvlc_media_list_player_t * p_mlp, libvlc_media_list_t * p_mlist)
- --
- 2.5.1
|