Commit efe23f26 authored by JP Dinger's avatar JP Dinger

Cosmetics: Remove need to (char*)"..." by making the target const, and replace...

Cosmetics: Remove need to (char*)"..." by making the target const, and replace a call to var_Get(bool) with var_GetBool.
parent ded081bc
...@@ -45,16 +45,12 @@ ...@@ -45,16 +45,12 @@
static void osd_UpdateState( osd_menu_state_t *, int, int, int, int, picture_t * ); static void osd_UpdateState( osd_menu_state_t *, int, int, int, int, picture_t * );
static inline osd_state_t *osd_VolumeStateChange( osd_state_t *, int ); static inline osd_state_t *osd_VolumeStateChange( osd_state_t *, int );
static int osd_VolumeStep( vlc_object_t *, int, int ); static int osd_VolumeStep( vlc_object_t *, int, int );
static bool osd_isVisible( osd_menu_t *p_osd );
static bool osd_ParserLoad( osd_menu_t *, const char * ); static bool osd_ParserLoad( osd_menu_t *, const char * );
static void osd_ParserUnload( osd_menu_t * ); static void osd_ParserUnload( osd_menu_t * );
static bool osd_isVisible( osd_menu_t *p_osd ) static inline bool osd_isVisible( osd_menu_t *p_osd )
{ {
vlc_value_t val; return var_GetBool( p_osd, "osd-menu-visible" );
var_Get( p_osd, "osd-menu-visible", &val );
return val.b_bool;
} }
static vlc_mutex_t *osd_GetMutex( vlc_object_t *p_this ) static vlc_mutex_t *osd_GetMutex( vlc_object_t *p_this )
...@@ -81,13 +77,13 @@ static bool osd_ParserLoad( osd_menu_t *p_menu, const char *psz_file ) ...@@ -81,13 +77,13 @@ static bool osd_ParserLoad( osd_menu_t *p_menu, const char *psz_file )
} }
else else
{ {
char *psz_type; const char *psz_type;
char *psz_ext = strrchr( p_menu->psz_file, '.' ); const char *psz_ext = strrchr( p_menu->psz_file, '.' );
if( psz_ext && !strcmp( psz_ext, ".cfg") ) if( psz_ext && !strcmp( psz_ext, ".cfg") )
psz_type = (char*)"import-osd"; psz_type = "import-osd";
else else
psz_type = (char*)"import-osd-xml"; psz_type = "import-osd-xml";
p_menu->p_parser = module_need( p_menu, "osd parser", p_menu->p_parser = module_need( p_menu, "osd parser",
psz_type, true ); psz_type, true );
......
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