[vlc-commits] libvlc: remove deprecated SD event manager
Rémi Denis-Courmont
git at videolan.org
Thu May 3 14:28:32 CEST 2018
vlc | branch: master | Rémi Denis-Courmont <remi at remlab.net> | Thu May 3 15:21:58 2018 +0300| [26d96c355a1310db1f481106d559d327db3ed7ca] | committer: Rémi Denis-Courmont
libvlc: remove deprecated SD event manager
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=26d96c355a1310db1f481106d559d327db3ed7ca
---
include/vlc/deprecated.h | 12 ------------
include/vlc/libvlc_events.h | 13 +------------
lib/event.c | 3 ---
lib/libvlc.sym | 1 -
lib/media_discoverer.c | 20 --------------------
5 files changed, 1 insertion(+), 48 deletions(-)
diff --git a/include/vlc/deprecated.h b/include/vlc/deprecated.h
index 445acae012..a7d0ad96bb 100644
--- a/include/vlc/deprecated.h
+++ b/include/vlc/deprecated.h
@@ -178,18 +178,6 @@ libvlc_media_discoverer_new_from_name( libvlc_instance_t * p_inst,
LIBVLC_DEPRECATED LIBVLC_API char *
libvlc_media_discoverer_localized_name( libvlc_media_discoverer_t * p_mdis );
-/**
- * Get event manager from media service discover object.
- *
- * \deprecated Useless, media_discoverer events are only triggered when calling
- * libvlc_media_discoverer_start() and libvlc_media_discoverer_stop().
- *
- * \param p_mdis media service discover object
- * \return event manager object.
- */
-LIBVLC_DEPRECATED LIBVLC_API libvlc_event_manager_t *
-libvlc_media_discoverer_event_manager( libvlc_media_discoverer_t * p_mdis );
-
/** @}*/
/**
diff --git a/include/vlc/libvlc_events.h b/include/vlc/libvlc_events.h
index baa83d50a8..e7083a7983 100644
--- a/include/vlc/libvlc_events.h
+++ b/include/vlc/libvlc_events.h
@@ -185,22 +185,11 @@ enum libvlc_event_e {
libvlc_MediaListPlayerStopped,
/**
- * \deprecated Useless event, it will be triggered only when calling
- * libvlc_media_discoverer_start()
- */
- libvlc_MediaDiscovererStarted=0x500,
- /**
- * \deprecated Useless event, it will be triggered only when calling
- * libvlc_media_discoverer_stop()
- */
- libvlc_MediaDiscovererEnded,
-
- /**
* A new \link #libvlc_renderer_item_t renderer item\endlink was found by a
* \link #libvlc_renderer_discoverer_t renderer discoverer\endlink.
* The renderer item is valid until deleted.
*/
- libvlc_RendererDiscovererItemAdded,
+ libvlc_RendererDiscovererItemAdded=0x502,
/**
* A previously discovered \link #libvlc_renderer_item_t renderer item\endlink
diff --git a/lib/event.c b/lib/event.c
index f027754181..7ac9d37886 100644
--- a/lib/event.c
+++ b/lib/event.c
@@ -189,9 +189,6 @@ static const event_name_t event_list[] = {
DEF(MediaListPlayerNextItemSet)
DEF(MediaListPlayerStopped)
- DEF(MediaDiscovererStarted)
- DEF(MediaDiscovererEnded)
-
DEF(VlmMediaAdded)
DEF(VlmMediaRemoved)
DEF(VlmMediaChanged)
diff --git a/lib/libvlc.sym b/lib/libvlc.sym
index a18f508d74..5ae867a693 100644
--- a/lib/libvlc.sym
+++ b/lib/libvlc.sym
@@ -63,7 +63,6 @@ libvlc_log_set_file
libvlc_log_unset
libvlc_media_add_option
libvlc_media_add_option_flag
-libvlc_media_discoverer_event_manager
libvlc_media_discoverer_is_running
libvlc_media_discoverer_localized_name
libvlc_media_discoverer_media_list
diff --git a/lib/media_discoverer.c b/lib/media_discoverer.c
index 367d7ea8e8..b2d5b9d5a1 100644
--- a/lib/media_discoverer.c
+++ b/lib/media_discoverer.c
@@ -41,7 +41,6 @@
struct libvlc_media_discoverer_t
{
- libvlc_event_manager_t event_manager;
libvlc_instance_t * p_libvlc_instance;
services_discovery_t * p_sd;
libvlc_media_list_t * p_mlist;
@@ -164,7 +163,6 @@ libvlc_media_discoverer_new( libvlc_instance_t * p_inst, const char * psz_name )
p_mdis->p_sd = NULL;
vlc_dictionary_init( &p_mdis->catname_to_submedialist, 0 );
- libvlc_event_manager_init( &p_mdis->event_manager, p_mdis );
libvlc_retain( p_inst );
strcpy( p_mdis->name, psz_name );
@@ -192,9 +190,6 @@ libvlc_media_discoverer_start( libvlc_media_discoverer_t * p_mdis )
return -1;
}
- libvlc_event_t event;
- event.type = libvlc_MediaDiscovererStarted;
- libvlc_event_send( &p_mdis->event_manager, &event );
return 0;
}
@@ -209,10 +204,6 @@ libvlc_media_discoverer_stop( libvlc_media_discoverer_t * p_mdis )
libvlc_media_list_internal_end_reached( p_mlist );
libvlc_media_list_unlock( p_mlist );
- libvlc_event_t event;
- event.type = libvlc_MediaDiscovererEnded;
- libvlc_event_send( &p_mdis->event_manager, &event );
-
vlc_sd_Destroy( p_mdis->p_sd );
p_mdis->p_sd = NULL;
}
@@ -261,7 +252,6 @@ libvlc_media_discoverer_release( libvlc_media_discoverer_t * p_mdis )
vlc_dictionary_clear( &p_mdis->catname_to_submedialist,
MediaListDictValueRelease, NULL );
- libvlc_event_manager_destroy( &p_mdis->event_manager );
libvlc_release( p_mdis->p_libvlc_instance );
free( p_mdis );
@@ -289,16 +279,6 @@ libvlc_media_discoverer_media_list( libvlc_media_discoverer_t * p_mdis )
}
/**************************************************************************
- * event_manager (Public)
- **************************************************************************/
-libvlc_event_manager_t *
-libvlc_media_discoverer_event_manager( libvlc_media_discoverer_t * p_mdis )
-{
- return &p_mdis->event_manager;
-}
-
-
-/**************************************************************************
* running (Public)
**************************************************************************/
int
More information about the vlc-commits
mailing list