[vlc-devel] [PATCH 2/2] hotkeys: Add hotkey for the BD disc popup menu action

Marvin Scholz epirat07 at gmail.com
Wed Dec 6 17:19:16 CET 2017


Fix #18772
---
 modules/control/hotkeys.c | 4 ++++
 src/libvlc-module.c       | 5 +++++
 2 files changed, 9 insertions(+)

diff --git a/modules/control/hotkeys.c b/modules/control/hotkeys.c
index 690a4e5e6c..13961afc89 100644
--- a/modules/control/hotkeys.c
+++ b/modules/control/hotkeys.c
@@ -972,6 +972,10 @@ static int PutAction( intf_thread_t *p_intf, input_thread_t *p_input,
             if( p_input )
                 var_SetInteger( p_input, "title  0", 2 );
             break;
+        case ACTIONID_DISC_POPUP_MENU:
+            if( p_input )
+                input_Control( p_input, INPUT_NAV_POPUP, NULL );
+            break;
         case ACTIONID_NAV_ACTIVATE:
             if( p_input )
                 input_Control( p_input, INPUT_NAV_ACTIVATE, NULL );
diff --git a/src/libvlc-module.c b/src/libvlc-module.c
index cc816873f7..3122f848c1 100644
--- a/src/libvlc-module.c
+++ b/src/libvlc-module.c
@@ -1298,6 +1298,8 @@ static const char *const mouse_wheel_texts[] = {
 #define NAV_ACTIVATE_KEY_LONGTEXT N_("Select the key to activate selected item in DVD menus.")
 #define DISC_MENU_TEXT N_("Go to the DVD menu")
 #define DISC_MENU_LONGTEXT N_("Select the key to take you to the DVD menu")
+#define DISC_POPUP_MENU_TEXT N_("Go to the BD popup menu")
+#define DISC_POPUP_MENU_LONGTEXT N_("Select the key to invoke the BD popup menu")
 #define TITLE_PREV_TEXT N_("Select previous DVD title")
 #define TITLE_PREV_LONGTEXT N_("Select the key to choose the previous title from the DVD")
 #define TITLE_NEXT_TEXT N_("Select next DVD title")
@@ -2264,6 +2266,7 @@ vlc_module_begin ()
 #   define KEY_INTF_BOSS          NULL
 #   define KEY_INTF_POPUP_MENU    "Menu"
 #   define KEY_DISC_MENU          "Ctrl+m"
+#   define KEY_DISC_POPUP_MENU    "Ctrl+Alt+m"
 #   define KEY_TITLE_PREV         "Ctrl+p"
 #   define KEY_TITLE_NEXT         "Ctrl+n"
 #   define KEY_CHAPTER_PREV       "Ctrl+u"
@@ -2526,6 +2529,8 @@ vlc_module_begin ()
 
     add_key( "key-disc-menu", KEY_DISC_MENU, DISC_MENU_TEXT,
              DISC_MENU_LONGTEXT, true )
+    add_key( "key-disc-popup-menu", KEY_DISC_POPUP_MENU, DISC_POPUP_MENU_TEXT,
+             DISC_POPUP_MENU_LONGTEXT, true )
     add_key( "key-title-prev", KEY_TITLE_PREV, TITLE_PREV_TEXT,
              TITLE_PREV_LONGTEXT, true )
     add_key( "key-title-next", KEY_TITLE_NEXT, TITLE_NEXT_TEXT,
-- 
2.14.3 (Apple Git-98)



More information about the vlc-devel mailing list