changeset 12841:96b807836eca

individual sub_select option not interferring with vobsub_lang
author alex
date Sat, 17 Jul 2004 12:47:12 +0000
parents e5fa67e8907e
children 5ab2ea430653
files input/input.c input/input.h mplayer.c
diffstat 3 files changed, 6 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/input/input.c	Sat Jul 17 11:22:14 2004 +0000
+++ b/input/input.c	Sat Jul 17 12:47:12 2004 +0000
@@ -78,6 +78,7 @@
   { MP_CMD_SUB_ALIGNMENT, "sub_alignment",0, { {MP_CMD_ARG_INT,{-1}}, {-1,{0}} } },
   { MP_CMD_SUB_VISIBILITY, "sub_visibility", 0, { {-1,{0}} } },
   { MP_CMD_VOBSUB_LANG, "vobsub_lang", 0, { {-1,{0}} } },
+  { MP_CMD_SUB_SELECT, "sub_select", 0, { {-1,{0}} } },
   { MP_CMD_GET_PERCENT_POS, "get_percent_pos", 0, { {-1,{0}} } },
   { MP_CMD_GET_TIME_LENGTH, "get_time_length", 0, { {-1,{0}} } },
 #ifdef USE_TV
@@ -303,6 +304,7 @@
   { { 't', 0 }, "sub_pos +1" },
   { { 'a', 0 }, "sub_alignment" },
   { { 'v', 0 }, "sub_visibility" },
+  { { 'b', 0 }, "sub_select" },
   { { 'j', 0 }, "vobsub_lang" },
   { { 'F', 0 }, "forced_subs_only" },
 #ifdef USE_EDL
--- a/input/input.h	Sat Jul 17 11:22:14 2004 +0000
+++ b/input/input.h	Sat Jul 17 12:47:12 2004 +0000
@@ -53,6 +53,7 @@
 #define MP_CMD_GET_SUB_VISIBILITY 49
 #define MP_CMD_SUB_FORCED_ONLY 50
 #define MP_CMD_VO_ONTOP 51
+#define MP_CMD_SUB_SELECT 52
 
 #define MP_CMD_GUI_EVENTS       5000
 #define MP_CMD_GUI_LOADFILE     5001
--- a/mplayer.c	Sat Jul 17 11:22:14 2004 +0000
+++ b/mplayer.c	Sat Jul 17 12:47:12 2004 +0000
@@ -3118,8 +3118,10 @@
 	    osd_show_vobsub_changed = 9;
 	vobsub_id = new_id;
     }
+        break;
+    case MP_CMD_SUB_SELECT:
 #ifdef USE_SUB  
-    else if (set_of_sub_size > 0){ //change subtitle file  
+    if (set_of_sub_size > 0){ //change subtitle file  
         set_of_sub_pos = (set_of_sub_pos + 1) % set_of_sub_size;
         subdata = set_of_subtitles[set_of_sub_pos];
         osd_show_sub_changed = sh_video->fps;