[vlc-commits] oldrc: fix "playlist" and "snapshot"
Rafaël Carré
git at videolan.org
Fri Jan 25 03:35:05 CET 2013
vlc | branch: master | Rafaël Carré <funman at videolan.org> | Fri Jan 25 03:31:35 2013 +0100| [79978963502973e943a7afab8666c308240a8b6b] | committer: Rafaël Carré
oldrc: fix "playlist" and "snapshot"
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=79978963502973e943a7afab8666c308240a8b6b
---
modules/control/rc.c | 12 +++++++++---
1 file changed, 9 insertions(+), 3 deletions(-)
diff --git a/modules/control/rc.c b/modules/control/rc.c
index 7f71dcb..6dc7d0f 100644
--- a/modules/control/rc.c
+++ b/modules/control/rc.c
@@ -624,9 +624,12 @@ static void *Run( void *data )
{
vlc_value_t val;
int i_ret;
-
val.psz_string = psz_arg;
- i_ret = var_Set( p_intf, psz_cmd, val );
+
+ if ((var_Type( p_intf, psz_cmd) & VLC_VAR_CLASS) == VLC_VAR_VOID)
+ i_ret = var_TriggerCallback( p_intf, psz_cmd );
+ else
+ i_ret = var_Set( p_intf, psz_cmd, val );
msg_rc( "%s: returned %i (%s)",
psz_cmd, i_ret, vlc_error( i_ret ) );
}
@@ -639,7 +642,10 @@ static void *Run( void *data )
val.psz_string = psz_arg;
/* FIXME: it's a global command, but we should pass the
* local object as an argument, not p_intf->p_libvlc. */
- i_ret = var_Set( p_intf->p_libvlc, psz_cmd, val );
+ if ((var_Type( p_intf->p_libvlc, psz_cmd) & VLC_VAR_CLASS) == VLC_VAR_VOID)
+ i_ret = var_TriggerCallback( p_intf, psz_cmd );
+ else
+ i_ret = var_Set( p_intf->p_libvlc, psz_cmd, val );
if( i_ret != 0 )
{
msg_rc( "%s: returned %i (%s)",
More information about the vlc-commits
mailing list