]> git.sesse.net Git - vlc/commitdiff
libvlc: intf-show and intf-popmenu must be created before interfaces are launched...
authorErwan Tulou <erwan10@videolan.org>
Tue, 16 Feb 2010 14:16:32 +0000 (15:16 +0100)
committerErwan Tulou <erwan10@videolan.org>
Tue, 16 Feb 2010 14:32:49 +0000 (15:32 +0100)
This fixes 'vlc -I rc --extraintf skins' that fails to add a callback to these
variables because they are not yet created
(pointed out by assert failed in debug mode when calling var_DelCallback)

src/libvlc.c

index 58f588a5ea70fcea0911fd2e91a641cb418b2406..fc7ad3991e06948930697a7dcfaa6c045881a007 100644 (file)
@@ -794,6 +794,13 @@ int libvlc_InternalInit( libvlc_int_t *p_libvlc, int i_argc,
      */
     vlc_InitActions( p_libvlc );
 
+    /* Create a variable for showing the fullscreen interface */
+    var_Create( p_libvlc, "intf-show", VLC_VAR_BOOL );
+    var_SetBool( p_libvlc, "intf-show", true );
+
+    /* Create a variable for showing the right click menu */
+    var_Create( p_libvlc, "intf-popupmenu", VLC_VAR_BOOL );
+
     /* variables for signalling creation of new files */
     var_Create( p_libvlc, "snapshot-file", VLC_VAR_STRING );
     var_Create( p_libvlc, "record-file", VLC_VAR_STRING );
@@ -950,13 +957,6 @@ int libvlc_InternalInit( libvlc_int_t *p_libvlc, int i_argc,
     var_Create( p_libvlc, "drawable-clip-right", VLC_VAR_INTEGER );
 
 
-    /* Create a variable for showing the fullscreen interface from hotkeys */
-    var_Create( p_libvlc, "intf-show", VLC_VAR_BOOL );
-    var_SetBool( p_libvlc, "intf-show", true );
-
-    /* Create a variable for showing the right click menu */
-    var_Create( p_libvlc, "intf-popupmenu", VLC_VAR_BOOL );
-
     /*
      * Get input filenames given as commandline arguments
      */