[vlc-devel] [PATCH 15/18] input:event: pass the ES category as enum es_format_category_e rather than int
Steve Lhomme
robux4 at videolabs.io
Wed Jul 5 17:00:29 CEST 2017
---
src/input/event.c | 8 ++++----
src/input/event.h | 6 +++---
2 files changed, 7 insertions(+), 7 deletions(-)
diff --git a/src/input/event.c b/src/input/event.c
index 5eab872d12..201c5c6fe3 100644
--- a/src/input/event.c
+++ b/src/input/event.c
@@ -228,7 +228,7 @@ void input_SendEventProgramScrambled( input_thread_t *p_input, int i_group, bool
Trigger( p_input, INPUT_EVENT_PROGRAM );
}
-static const char *GetEsVarName( int i_cat )
+static const char *GetEsVarName( enum es_format_category_e i_cat )
{
switch( i_cat )
{
@@ -242,20 +242,20 @@ static const char *GetEsVarName( int i_cat )
return NULL;
}
}
-void input_SendEventEsAdd( input_thread_t *p_input, int i_cat, int i_id, const char *psz_text )
+void input_SendEventEsAdd( input_thread_t *p_input, enum es_format_category_e i_cat, int i_id, const char *psz_text )
{
const char *psz_varname = GetEsVarName( i_cat );
if( psz_varname )
VarListAdd( p_input, psz_varname, INPUT_EVENT_ES, i_id, psz_text );
}
-void input_SendEventEsDel( input_thread_t *p_input, int i_cat, int i_id )
+void input_SendEventEsDel( input_thread_t *p_input, enum es_format_category_e i_cat, int i_id )
{
const char *psz_varname = GetEsVarName( i_cat );
if( psz_varname )
VarListDel( p_input, psz_varname, INPUT_EVENT_ES, i_id );
}
/* i_id == -1 will unselect */
-void input_SendEventEsSelect( input_thread_t *p_input, int i_cat, int i_id )
+void input_SendEventEsSelect( input_thread_t *p_input, enum es_format_category_e i_cat, int i_id )
{
const char *psz_varname = GetEsVarName( i_cat );
if( psz_varname )
diff --git a/src/input/event.h b/src/input/event.h
index d936f3c304..156b992059 100644
--- a/src/input/event.h
+++ b/src/input/event.h
@@ -57,9 +57,9 @@ void input_SendEventProgramDel( input_thread_t *p_input, int i_program );
void input_SendEventProgramSelect( input_thread_t *p_input, int i_program );
void input_SendEventProgramScrambled( input_thread_t *p_input, int i_group, bool b_scrambled );
-void input_SendEventEsDel( input_thread_t *p_input, int i_cat, int i_id );
-void input_SendEventEsAdd( input_thread_t *p_input, int i_cat, int i_id, const char *psz_text );
-void input_SendEventEsSelect( input_thread_t *p_input, int i_cat, int i_id ); /* i_id == -1 will unselect */
+void input_SendEventEsDel( input_thread_t *p_input, enum es_format_category_e i_cat, int i_id );
+void input_SendEventEsAdd( input_thread_t *p_input, enum es_format_category_e i_cat, int i_id, const char *psz_text );
+void input_SendEventEsSelect( input_thread_t *p_input, enum es_format_category_e i_cat, int i_id ); /* i_id == -1 will unselect */
void input_SendEventTeletextAdd( input_thread_t *p_input,
int i_teletext, const char *psz_text );
--
2.12.1
More information about the vlc-devel
mailing list