]> git.sesse.net Git - vlc/blobdiff - modules/control/lirc.c
Use var_InheritString for --decklink-video-connection.
[vlc] / modules / control / lirc.c
index 2391874a8a01e08c26748fe5ee3da2a811b83afa..5688c97ab106c2e64038f3d05faf42d113b62ff3 100644 (file)
@@ -35,6 +35,7 @@
 #include <vlc_plugin.h>
 #include <vlc_interface.h>
 #include <vlc_osd.h>
+#include <vlc_keys.h>
 
 #ifdef HAVE_POLL
 # include <poll.h>
@@ -42,7 +43,7 @@
 
 #include <lirc/lirc_client.h>
 
-#define LIRC_TEXT N_("Change the lirc configuration file.")
+#define LIRC_TEXT N_("Change the lirc configuration file")
 #define LIRC_LONGTEXT N_( \
     "Tell lirc to read this configuration file. By default it " \
     "searches in the users home directory." )
@@ -179,8 +180,11 @@ static void Process( intf_thread_t *p_intf )
         {
             if( !strncmp( "key-", c, 4 ) )
             {
-                int i_keyval = config_GetInt( p_intf, c );
-                var_SetInteger( p_intf->p_libvlc, "key-pressed", i_keyval );
+                vlc_key_t i_key = vlc_GetActionId( c );
+                if( i_key )
+                    var_SetInteger( p_intf->p_libvlc, "key-action", i_key );
+                else
+                    msg_Err( p_intf, "Unknown hotkey '%s'", c );
             }
             else if( !strncmp( "menu ", c, 5)  )
             {