annotate gui/dialog/menu.c @ 36701:eb1a6a0b268f

Make unknown audio language translatable.
author ib
date Fri, 07 Feb 2014 18:14:22 +0000
parents 9f19f1bd34eb
children fb14d0cfc36d
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
1 /*
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
2 * This file is part of MPlayer.
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
3 *
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
4 * MPlayer is free software; you can redistribute it and/or modify
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
5 * it under the terms of the GNU General Public License as published by
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
6 * the Free Software Foundation; either version 2 of the License, or
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
7 * (at your option) any later version.
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
8 *
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
9 * MPlayer is distributed in the hope that it will be useful,
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
12 * GNU General Public License for more details.
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
13 *
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
14 * You should have received a copy of the GNU General Public License along
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
15 * with MPlayer; if not, write to the Free Software Foundation, Inc.,
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
16 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
17 */
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
18
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
19 #include <stdio.h>
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
20 #include <stdlib.h>
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
21 #include <string.h>
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
22
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
23 #include "config.h"
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
24 #include "help_mp.h"
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
25 #include "access_mpcontext.h"
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
26 #include "mixer.h"
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
27 #include "mpcommon.h"
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
28
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
29 #include "menu.h"
35529
8ad4d2fb46e8 Rebuild GUI directory structure.
ib
parents: 35528
diff changeset
30 #include "dialog.h"
35772
3fec1d4b2736 Relocate uiMainEvent() prototype.
ib
parents: 35768
diff changeset
31 #include "gui/ui/actions.h"
35525
e27855a45128 Rebuild GUI directory structure.
ib
parents: 35493
diff changeset
32 #include "gui/app/app.h"
e27855a45128 Rebuild GUI directory structure.
ib
parents: 35493
diff changeset
33 #include "gui/app/gui.h"
33738
998f94e62a61 Remove unnecessary #include "gui/interface.h".
ib
parents: 33657
diff changeset
34 #include "gui/interface.h"
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
35
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
36 #include "stream/stream.h"
36273
55cac32d68c2 Add check marks to the video aspect ratio menu items.
ib
parents: 36261
diff changeset
37 #include "libavutil/common.h"
55cac32d68c2 Add check marks to the video aspect ratio menu items.
ib
parents: 36261
diff changeset
38 #include "libmpcodecs/vd.h"
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
39 #include "libmpdemux/demuxer.h"
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
40 #include "libmpdemux/stheader.h"
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
41 #include "libavutil/avstring.h"
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
42
35526
3c901704a27c Rebuild GUI directory structure.
ib
parents: 35525
diff changeset
43 #include "pixmaps/about.xpm"
3c901704a27c Rebuild GUI directory structure.
ib
parents: 35525
diff changeset
44 #include "pixmaps/half.xpm"
3c901704a27c Rebuild GUI directory structure.
ib
parents: 35525
diff changeset
45 #include "pixmaps/normal.xpm"
3c901704a27c Rebuild GUI directory structure.
ib
parents: 35525
diff changeset
46 #include "pixmaps/double.xpm"
3c901704a27c Rebuild GUI directory structure.
ib
parents: 35525
diff changeset
47 #include "pixmaps/full.xpm"
3c901704a27c Rebuild GUI directory structure.
ib
parents: 35525
diff changeset
48 #include "pixmaps/exit.xpm"
3c901704a27c Rebuild GUI directory structure.
ib
parents: 35525
diff changeset
49 #include "pixmaps/prefs.xpm"
3c901704a27c Rebuild GUI directory structure.
ib
parents: 35525
diff changeset
50 #include "pixmaps/equalizer.xpm"
3c901704a27c Rebuild GUI directory structure.
ib
parents: 35525
diff changeset
51 #include "pixmaps/playlist.xpm"
3c901704a27c Rebuild GUI directory structure.
ib
parents: 35525
diff changeset
52 #include "pixmaps/skin.xpm"
3c901704a27c Rebuild GUI directory structure.
ib
parents: 35525
diff changeset
53 #include "pixmaps/sound.xpm"
3c901704a27c Rebuild GUI directory structure.
ib
parents: 35525
diff changeset
54 #include "pixmaps/open.xpm"
3c901704a27c Rebuild GUI directory structure.
ib
parents: 35525
diff changeset
55 #include "pixmaps/play.xpm"
3c901704a27c Rebuild GUI directory structure.
ib
parents: 35525
diff changeset
56 #include "pixmaps/stop.xpm"
3c901704a27c Rebuild GUI directory structure.
ib
parents: 35525
diff changeset
57 #include "pixmaps/pause.xpm"
3c901704a27c Rebuild GUI directory structure.
ib
parents: 35525
diff changeset
58 #include "pixmaps/prev.xpm"
3c901704a27c Rebuild GUI directory structure.
ib
parents: 35525
diff changeset
59 #include "pixmaps/next.xpm"
3c901704a27c Rebuild GUI directory structure.
ib
parents: 35525
diff changeset
60 #include "pixmaps/aspect.xpm"
3c901704a27c Rebuild GUI directory structure.
ib
parents: 35525
diff changeset
61 #include "pixmaps/aspect11.xpm"
3c901704a27c Rebuild GUI directory structure.
ib
parents: 35525
diff changeset
62 #include "pixmaps/aspect169.xpm"
3c901704a27c Rebuild GUI directory structure.
ib
parents: 35525
diff changeset
63 #include "pixmaps/aspect235.xpm"
3c901704a27c Rebuild GUI directory structure.
ib
parents: 35525
diff changeset
64 #include "pixmaps/aspect43.xpm"
3c901704a27c Rebuild GUI directory structure.
ib
parents: 35525
diff changeset
65 #include "pixmaps/file2.xpm"
3c901704a27c Rebuild GUI directory structure.
ib
parents: 35525
diff changeset
66 #include "pixmaps/url.xpm"
3c901704a27c Rebuild GUI directory structure.
ib
parents: 35525
diff changeset
67 #include "pixmaps/sub.xpm"
3c901704a27c Rebuild GUI directory structure.
ib
parents: 35525
diff changeset
68 #include "pixmaps/nosub.xpm"
3c901704a27c Rebuild GUI directory structure.
ib
parents: 35525
diff changeset
69 #include "pixmaps/empty.xpm"
3c901704a27c Rebuild GUI directory structure.
ib
parents: 35525
diff changeset
70 #include "pixmaps/loadeaf.xpm"
3c901704a27c Rebuild GUI directory structure.
ib
parents: 35525
diff changeset
71 #include "pixmaps/title.xpm"
3c901704a27c Rebuild GUI directory structure.
ib
parents: 35525
diff changeset
72 #include "pixmaps/subtitle.xpm"
34387
0ba85cad4c7e Add audio CD playback support to the X11/GTK GUI.
ib
parents: 34333
diff changeset
73 #ifdef CONFIG_CDDA
35526
3c901704a27c Rebuild GUI directory structure.
ib
parents: 35525
diff changeset
74 #include "pixmaps/cd.xpm"
3c901704a27c Rebuild GUI directory structure.
ib
parents: 35525
diff changeset
75 #include "pixmaps/playcd.xpm"
34387
0ba85cad4c7e Add audio CD playback support to the X11/GTK GUI.
ib
parents: 34333
diff changeset
76 #endif
34077
deff81b57903 Cosmetic: Order STREAMTYPE related code.
ib
parents: 33951
diff changeset
77 #ifdef CONFIG_VCD
35526
3c901704a27c Rebuild GUI directory structure.
ib
parents: 35525
diff changeset
78 #include "pixmaps/vcd.xpm"
3c901704a27c Rebuild GUI directory structure.
ib
parents: 35525
diff changeset
79 #include "pixmaps/playvcd.xpm"
34077
deff81b57903 Cosmetic: Order STREAMTYPE related code.
ib
parents: 33951
diff changeset
80 #endif
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
81 #ifdef CONFIG_DVDREAD
35526
3c901704a27c Rebuild GUI directory structure.
ib
parents: 35525
diff changeset
82 #include "pixmaps/dvd.xpm"
3c901704a27c Rebuild GUI directory structure.
ib
parents: 35525
diff changeset
83 #include "pixmaps/playdvd.xpm"
3c901704a27c Rebuild GUI directory structure.
ib
parents: 35525
diff changeset
84 #include "pixmaps/chapter.xpm"
3c901704a27c Rebuild GUI directory structure.
ib
parents: 35525
diff changeset
85 #include "pixmaps/dolby.xpm"
36665
045bb0dcea27 Add new audio pixmap.
ib
parents: 36664
diff changeset
86 #include "pixmaps/audio.xpm"
36666
1862771a5ba9 Add new video pixmap.
ib
parents: 36665
diff changeset
87 #include "pixmaps/video.xpm"
34422
b1f2949ca18d Use empty1px.xpm instead of empty.xpm for check item (and similar) menus.
ib
parents: 34421
diff changeset
88 #endif
36429
28ea255e40ce Add support for TV/DVB to the GUI.
ib
parents: 36316
diff changeset
89 #ifdef CONFIG_TV
28ea255e40ce Add support for TV/DVB to the GUI.
ib
parents: 36316
diff changeset
90 #include "pixmaps/tv.xpm"
28ea255e40ce Add support for TV/DVB to the GUI.
ib
parents: 36316
diff changeset
91 #endif
35526
3c901704a27c Rebuild GUI directory structure.
ib
parents: 35525
diff changeset
92 #include "pixmaps/empty1px.xpm"
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
93
36029
49be954ad61a Move variable declarations and definitions where they belong.
ib
parents: 36028
diff changeset
94 int gtkPopupMenu;
49be954ad61a Move variable declarations and definitions where they belong.
ib
parents: 36028
diff changeset
95 int gtkPopupMenuParam;
49be954ad61a Move variable declarations and definitions where they belong.
ib
parents: 36028
diff changeset
96
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
97 static void ActivateMenuItem( int Item )
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
98 {
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
99 // fprintf( stderr,"[menu] item: %d.%d\n",Item&0xffff,Item>>16 );
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
100 gtkPopupMenu=Item & 0x0000ffff;
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
101 gtkPopupMenuParam=Item >> 16;
35773
c688b0dcbe66 Cosmetic: Rename uiMainEvent() uiEvent().
ib
parents: 35772
diff changeset
102 uiEvent( Item & 0x0000ffff,Item >> 16 );
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
103 }
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
104
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
105 static GtkWidget * AddMenuCheckItem(GtkWidget *window1, const char * immagine_xpm, GtkWidget* Menu,const char* label, gboolean state, int Number)
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
106 {
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
107 GtkWidget * Label = NULL;
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
108 GtkWidget * Pixmap = NULL;
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
109 GtkWidget * hbox = NULL;
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
110 GtkWidget * Item = NULL;
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
111
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
112 GdkPixmap *PixmapIcon = NULL;
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
113 GdkColor transparent;
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
114 GdkBitmap *MaskIcon = NULL;
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
115
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
116 PixmapIcon = gdk_pixmap_create_from_xpm_d (window1->window, &MaskIcon, &transparent,(gchar **)immagine_xpm );
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
117 Pixmap = gtk_pixmap_new (PixmapIcon, MaskIcon);
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
118 gdk_pixmap_unref (PixmapIcon);
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
119
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
120 Item=gtk_check_menu_item_new();
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
121 Label = gtk_label_new (label);
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
122
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
123 hbox = gtk_hbox_new (FALSE, 8);
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
124 gtk_box_pack_start (GTK_BOX (hbox), Pixmap, FALSE, FALSE, 0);
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
125 gtk_box_pack_start (GTK_BOX (hbox), Label, FALSE, FALSE, 0);
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
126 gtk_container_add (GTK_CONTAINER (Item), hbox);
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
127
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
128 gtk_menu_append( GTK_MENU( Menu ),Item );
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
129
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
130 gtk_check_menu_item_set_active(GTK_CHECK_MENU_ITEM(Item),state);
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
131 gtk_signal_connect_object( GTK_OBJECT(Item),"activate",
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
132 GTK_SIGNAL_FUNC(ActivateMenuItem),(gpointer)Number );
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
133 gtk_menu_item_right_justify (GTK_MENU_ITEM (Item));
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
134 gtk_widget_show_all(Item);
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
135
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
136 return Item;
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
137 }
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
138 GtkWidget * AddMenuItem( GtkWidget *window1, const char * immagine_xpm, GtkWidget * SubMenu,const char * label,int Number )
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
139 {
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
140 GtkWidget * Label = NULL;
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
141 GtkWidget * Pixmap = NULL;
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
142 GtkWidget * hbox = NULL;
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
143 GtkWidget * Item = NULL;
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
144 GdkPixmap * PixmapIcon = NULL;
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
145 GdkColor transparent;
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
146 GdkBitmap * MaskIcon = NULL;
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
147
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
148 PixmapIcon = gdk_pixmap_create_from_xpm_d (window1->window, &MaskIcon, &transparent,(gchar **)immagine_xpm );
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
149 Pixmap = gtk_pixmap_new (PixmapIcon, MaskIcon);
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
150 gdk_pixmap_unref (PixmapIcon);
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
151
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
152 Item=gtk_menu_item_new();
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
153 Label = gtk_label_new (label);
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
154
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
155 hbox = gtk_hbox_new (FALSE, 8);
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
156 gtk_box_pack_start (GTK_BOX (hbox), Pixmap, FALSE, FALSE, 0);
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
157 gtk_box_pack_start (GTK_BOX (hbox), Label, FALSE, FALSE, 0);
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
158 gtk_container_add (GTK_CONTAINER (Item), hbox);
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
159
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
160
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
161 gtk_menu_append( GTK_MENU( SubMenu ),Item );
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
162 gtk_signal_connect_object( GTK_OBJECT(Item),"activate",
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
163 GTK_SIGNAL_FUNC(ActivateMenuItem),(gpointer)Number );
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
164
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
165 gtk_menu_item_right_justify (GTK_MENU_ITEM (Item));
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
166 gtk_widget_show_all(Item);
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
167 return Item;
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
168 }
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
169
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
170
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
171 GtkWidget * AddSubMenu( GtkWidget *window1, const char * immagine_xpm, GtkWidget * Menu,const char * label )
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
172 {
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
173 GtkWidget * Label = NULL;
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
174 GtkWidget * Pixmap = NULL;
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
175 GtkWidget * hbox = NULL;
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
176 GtkWidget * Item = NULL;
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
177 GtkWidget * SubItem = NULL;
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
178 GdkPixmap * PixmapIcon = NULL;
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
179 GdkColor transparent;
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
180 GdkBitmap * MaskIcon = NULL;
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
181
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
182 PixmapIcon = gdk_pixmap_create_from_xpm_d (window1->window, &MaskIcon, &transparent,(gchar **)immagine_xpm);
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
183 Pixmap = gtk_pixmap_new (PixmapIcon, MaskIcon);
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
184 gdk_pixmap_unref (PixmapIcon);
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
185
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
186 SubItem=gtk_menu_item_new();
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
187 Item=gtk_menu_new();
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
188 Label = gtk_label_new (label);
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
189
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
190 hbox = gtk_hbox_new (FALSE, 8);
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
191 gtk_box_pack_start (GTK_BOX (hbox), Pixmap, FALSE, FALSE, 0);
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
192 gtk_box_pack_start (GTK_BOX (hbox), Label, FALSE, FALSE, 0);
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
193 gtk_container_add (GTK_CONTAINER (SubItem), hbox);
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
194
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
195 gtk_menu_append( GTK_MENU( Menu ),SubItem );
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
196 gtk_menu_item_set_submenu( GTK_MENU_ITEM( SubItem ),Item );
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
197
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
198 gtk_widget_show_all( SubItem );
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
199 return Item;
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
200 }
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
201
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
202 GtkWidget * AddSeparator( GtkWidget * Menu )
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
203 {
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
204 GtkWidget * Item = NULL;
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
205
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
206 Item=gtk_menu_item_new ();
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
207 gtk_widget_show( Item );
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
208 gtk_container_add( GTK_CONTAINER( Menu ),Item );
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
209 gtk_widget_set_sensitive( Item,FALSE );
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
210
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
211 return Item;
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
212 }
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
213
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
214 typedef struct
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
215 {
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
216 int id;
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
217 const char * name;
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
218 } Languages_t;
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
219
34454
5a45efc630b8 Remove all unnecessary #ifdefs from GUI code.
ib
parents: 34423
diff changeset
220 #ifdef CONFIG_DVDREAD
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
221 #define lng( a,b ) ( (int)(a) * 256 + b )
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
222 static Languages_t Languages[] =
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
223 {
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
224 { lng( 'a','b' ), "Abkhazian" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
225 { lng( 'a','a' ), "Afar" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
226 { lng( 'a','f' ), "Afrikaans" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
227 { lng( 's','q' ), "Albanian" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
228 { lng( 'a','m' ), "Amharic" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
229 { lng( 'a','r' ), "Arabic" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
230 { lng( 'h','y' ), "Armenian" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
231 { lng( 'a','s' ), "Assamese" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
232 { lng( 'a','e' ), "Avestan" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
233 { lng( 'a','y' ), "Aymara" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
234 { lng( 'a','z' ), "Azerbaijani" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
235 { lng( 'b','a' ), "Bashkir" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
236 { lng( 'e','u' ), "Basque" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
237 { lng( 'b','e' ), "Belarusian" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
238 { lng( 'b','n' ), "Bengali" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
239 { lng( 'b','h' ), "Bihari" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
240 { lng( 'b','i' ), "Bislama" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
241 { lng( 'b','s' ), "Bosnian" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
242 { lng( 'b','r' ), "Breton" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
243 { lng( 'b','g' ), "Bulgarian" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
244 { lng( 'm','y' ), "Burmese" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
245 { lng( 'c','a' ), "Catalan" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
246 { lng( 'c','h' ), "Chamorro" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
247 { lng( 'c','e' ), "Chechen" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
248 { lng( 'n','y' ), "Chichewa;Nyanja" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
249 { lng( 'z','h' ), "Chinese" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
250 { lng( 'c','u' ), "ChurchSlavic" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
251 { lng( 'c','v' ), "Chuvash" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
252 { lng( 'k','w' ), "Cornish" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
253 { lng( 'c','o' ), "Corsican" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
254 { lng( 'h','r' ), "Croatian" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
255 { lng( 'c','s' ), "Czech" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
256 { lng( 'd','a' ), "Danish" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
257 { lng( 'n','l' ), "Dutch" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
258 { lng( 'd','z' ), "Dzongkha" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
259 { lng( 'e','n' ), "English" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
260 { lng( 'e','o' ), "Esperanto" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
261 { lng( 'e','t' ), "Estonian" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
262 { lng( 'f','o' ), "Faroese" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
263 { lng( 'f','j' ), "Fijian" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
264 { lng( 'f','i' ), "Finnish" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
265 { lng( 'f','r' ), "French" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
266 { lng( 'f','y' ), "Frisian" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
267 { lng( 'g','d' ), "Gaelic(Scots" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
268 { lng( 'g','l' ), "Gallegan" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
269 { lng( 'k','a' ), "Georgian" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
270 { lng( 'd','e' ), "German" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
271 { lng( 'e','l' ), "Greek" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
272 { lng( 'g','n' ), "Guarani" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
273 { lng( 'g','u' ), "Gujarati" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
274 { lng( 'h','a' ), "Hausa" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
275 { lng( 'h','e' ), "Hebrew" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
276 { lng( 'i','w' ), "Hebrew" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
277 { lng( 'h','z' ), "Herero" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
278 { lng( 'h','i' ), "Hindi" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
279 { lng( 'h','o' ), "HiriMotu" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
280 { lng( 'h','u' ), "Hungarian" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
281 { lng( 'i','s' ), "Icelandic" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
282 { lng( 'i','d' ), "Indonesian" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
283 { lng( 'i','n' ), "Indonesian" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
284 { lng( 'i','a' ), "Interlingua" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
285 { lng( 'i','e' ), "Interlingue" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
286 { lng( 'i','u' ), "Inuktitut" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
287 { lng( 'i','k' ), "Inupiaq" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
288 { lng( 'g','a' ), "Irish" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
289 { lng( 'i','t' ), "Italian" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
290 { lng( 'j','a' ), "Japanese" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
291 { lng( 'j','v' ), "Javanese" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
292 { lng( 'j','w' ), "Javanese" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
293 { lng( 'k','l' ), "Kalaallisut" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
294 { lng( 'k','n' ), "Kannada" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
295 { lng( 'k','s' ), "Kashmiri" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
296 { lng( 'k','k' ), "Kazakh" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
297 { lng( 'k','m' ), "Khmer" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
298 { lng( 'k','i' ), "Kikuyu" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
299 { lng( 'r','w' ), "Kinyarwanda" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
300 { lng( 'k','y' ), "Kirghiz" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
301 { lng( 'k','v' ), "Komi" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
302 { lng( 'k','o' ), "Korean" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
303 { lng( 'k','j' ), "Kuanyama" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
304 { lng( 'k','u' ), "Kurdish" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
305 { lng( 'l','o' ), "Lao" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
306 { lng( 'l','a' ), "Latin" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
307 { lng( 'l','v' ), "Latvian" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
308 { lng( 'l','b' ), "Letzeburgesch" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
309 { lng( 'l','n' ), "Lingala" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
310 { lng( 'l','t' ), "Lithuanian" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
311 { lng( 'm','k' ), "Macedonian" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
312 { lng( 'm','g' ), "Malagasy" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
313 { lng( 'm','s' ), "Malay" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
314 { lng( 'm','l' ), "Malayalam" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
315 { lng( 'm','t' ), "Maltese" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
316 { lng( 'g','v' ), "Manx" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
317 { lng( 'm','i' ), "Maori" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
318 { lng( 'm','r' ), "Marathi" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
319 { lng( 'm','h' ), "Marshall" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
320 { lng( 'm','o' ), "Moldavian" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
321 { lng( 'm','n' ), "Mongolian" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
322 { lng( 'n','a' ), "Nauru" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
323 { lng( 'n','v' ), "Navajo" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
324 { lng( 'n','d' ), "North Ndebele" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
325 { lng( 'n','r' ), "South Ndebele" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
326 { lng( 'n','g' ), "Ndonga" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
327 { lng( 'n','e' ), "Nepali" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
328 { lng( 's','e' ), "NorthernSami" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
329 { lng( 'n','o' ), "Norwegian" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
330 { lng( 'n','b' ), "NorwegianBokmål" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
331 { lng( 'n','n' ), "NorwegianNynorsk" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
332 { lng( 'n','y' ), "Nyanja;Chichewa" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
333 { lng( 'o','c' ), "Occitan(post1500;Provençal" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
334 { lng( 'o','r' ), "Oriya" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
335 { lng( 'o','m' ), "Oromo" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
336 { lng( 'o','s' ), "Ossetian;Ossetic" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
337 { lng( 'p','i' ), "Pali" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
338 { lng( 'p','a' ), "Panjabi" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
339 { lng( 'f','a' ), "Persian" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
340 { lng( 'p','l' ), "Polish" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
341 { lng( 'p','t' ), "Portuguese" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
342 { lng( 'o','c' ), "Provençal;Occitan(post1500" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
343 { lng( 'p','s' ), "Pushto" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
344 { lng( 'q','u' ), "Quechua" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
345 { lng( 'r','m' ), "Raeto-Romance" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
346 { lng( 'r','o' ), "Romanian" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
347 { lng( 'r','n' ), "Rundi" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
348 { lng( 'r','u' ), "Russian" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
349 { lng( 's','m' ), "Samoan" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
350 { lng( 's','g' ), "Sango" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
351 { lng( 's','a' ), "Sanskrit" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
352 { lng( 's','c' ), "Sardinian" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
353 { lng( 's','r' ), "Serbian" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
354 { lng( 's','n' ), "Shona" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
355 { lng( 's','d' ), "Sindhi" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
356 { lng( 's','i' ), "Sinhalese" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
357 { lng( 's','k' ), "Slovak" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
358 { lng( 's','l' ), "Slovenian" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
359 { lng( 's','o' ), "Somali" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
360 { lng( 's','t' ), "Sotho" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
361 { lng( 'e','s' ), "Spanish" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
362 { lng( 's','u' ), "Sundanese" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
363 { lng( 's','w' ), "Swahili" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
364 { lng( 's','s' ), "Swati" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
365 { lng( 's','v' ), "Swedish" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
366 { lng( 't','l' ), "Tagalog" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
367 { lng( 't','y' ), "Tahitian" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
368 { lng( 't','g' ), "Tajik" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
369 { lng( 't','a' ), "Tamil" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
370 { lng( 't','t' ), "Tatar" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
371 { lng( 't','e' ), "Telugu" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
372 { lng( 't','h' ), "Thai" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
373 { lng( 'b','o' ), "Tibetan" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
374 { lng( 't','i' ), "Tigrinya" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
375 { lng( 't','o' ), "Tonga" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
376 { lng( 't','s' ), "Tsonga" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
377 { lng( 't','n' ), "Tswana" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
378 { lng( 't','r' ), "Turkish" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
379 { lng( 't','k' ), "Turkmen" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
380 { lng( 't','w' ), "Twi" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
381 { lng( 'u','g' ), "Uighur" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
382 { lng( 'u','k' ), "Ukrainian" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
383 { lng( 'u','r' ), "Urdu" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
384 { lng( 'u','z' ), "Uzbek" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
385 { lng( 'v','i' ), "Vietnamese" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
386 { lng( 'v','o' ), "Volapük" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
387 { lng( 'c','y' ), "Welsh" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
388 { lng( 'w','o' ), "Wolof" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
389 { lng( 'x','h' ), "Xhosa" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
390 { lng( 'y','i' ), "Yiddish" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
391 { lng( 'j','i' ), "Yiddish" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
392 { lng( 'y','o' ), "Yoruba" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
393 { lng( 'z','a' ), "Zhuang" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
394 { lng( 'z','u' ), "Zulu" },
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
395 };
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
396 #undef lng
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
397
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
398 static char * ChannelTypes[] =
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
399 { "Dolby Digital","","Mpeg1","Mpeg2","PCM","","Digital Theatre System" };
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
400 static char * ChannelNumbers[] =
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
401 { "","Stereo","","","","5.1" };
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
402
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
403 static const char * GetLanguage( int language )
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
404 {
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
405 unsigned int i;
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
406 for ( i=0;i<sizeof( Languages ) / sizeof( Languages_t );i++ )
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
407 if ( Languages[i].id == language ) return Languages[i].name;
36701
eb1a6a0b268f Make unknown audio language translatable.
ib
parents: 36700
diff changeset
408 return MSGTR_GUI_Unknown;
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
409 }
34454
5a45efc630b8 Remove all unnecessary #ifdefs from GUI code.
ib
parents: 34423
diff changeset
410 #endif
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
411
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
412
36028
8c62c9931075 Make variable DVDSubMenu static.
ib
parents: 35996
diff changeset
413 static GtkWidget * DVDSubMenu;
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
414 GtkWidget * DVDTitleMenu;
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
415 GtkWidget * DVDChapterMenu;
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
416 GtkWidget * DVDAudioLanguageMenu;
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
417 GtkWidget * DVDSubtitleLanguageMenu;
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
418 GtkWidget * AspectMenu;
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
419 GtkWidget * VCDSubMenu;
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
420 GtkWidget * VCDTitleMenu;
34387
0ba85cad4c7e Add audio CD playback support to the X11/GTK GUI.
ib
parents: 34333
diff changeset
421 GtkWidget * CDSubMenu;
0ba85cad4c7e Add audio CD playback support to the X11/GTK GUI.
ib
parents: 34333
diff changeset
422 GtkWidget * CDTitleMenu;
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
423
35996
6c891a0e3fea Cosmetic: Rename the functions creating the dialogs.
ib
parents: 35773
diff changeset
424 GtkWidget * CreatePopUpMenu( void )
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
425 {
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
426 GtkWidget * window1;
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
427 GtkWidget * Menu = NULL;
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
428 GtkWidget * SubMenu = NULL;
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
429 GtkWidget * MenuItem = NULL;
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
430 GtkWidget * H, * N, * D, * F;
33657
c92f23eac7a4 Remove guiGetEvent type guiSetDemuxer.
ib
parents: 33655
diff changeset
431 demuxer_t *demuxer = mpctx_get_demuxer(guiInfo.mpcontext);
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
432 mixer_t *mixer = mpctx_get_mixer(guiInfo.mpcontext);
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
433 int global_sub_size = mpctx_get_global_sub_size(guiInfo.mpcontext);
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
434
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
435 Menu=gtk_menu_new();
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
436 gtk_widget_realize (Menu);
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
437 window1 = gtk_widget_get_toplevel(Menu);
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
438
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
439
36694
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
440 AddMenuItem( window1, (const char*)about_xpm, Menu,MSGTR_GUI_AboutMPlayer" ", evAbout );
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
441 AddSeparator( Menu );
36694
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
442 SubMenu=AddSubMenu( window1, (const char*)open_xpm, Menu,MSGTR_GUI_Open );
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
443 AddMenuItem( window1, (const char*)file2_xpm, SubMenu,MSGTR_GUI_File"... ", evLoadPlay );
34387
0ba85cad4c7e Add audio CD playback support to the X11/GTK GUI.
ib
parents: 34333
diff changeset
444 #ifdef CONFIG_CDDA
36694
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
445 AddMenuItem( window1, (const char*)playcd_xpm, SubMenu,MSGTR_GUI_CD, evPlayCD );
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
446 CDSubMenu=AddSubMenu( window1, (const char*)cd_xpm, Menu,MSGTR_GUI_CD );
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
447 AddMenuItem( window1, (const char*)playcd_xpm, CDSubMenu,MSGTR_GUI_Play,evPlayCD );
34387
0ba85cad4c7e Add audio CD playback support to the X11/GTK GUI.
ib
parents: 34333
diff changeset
448 AddSeparator( CDSubMenu );
36694
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
449 CDTitleMenu=AddSubMenu( window1, (const char*)title_xpm, CDSubMenu,MSGTR_GUI_Titles );
34420
0b31cf6cec25 Fix bug in CD / VCD / DVD related menus.
ib
parents: 34419
diff changeset
450 if ( guiInfo.Tracks && ( guiInfo.StreamType == STREAMTYPE_CDDA ) )
34387
0ba85cad4c7e Add audio CD playback support to the X11/GTK GUI.
ib
parents: 34333
diff changeset
451 {
0ba85cad4c7e Add audio CD playback support to the X11/GTK GUI.
ib
parents: 34333
diff changeset
452 char tmp[32]; int i;
0ba85cad4c7e Add audio CD playback support to the X11/GTK GUI.
ib
parents: 34333
diff changeset
453 for ( i=1;i <= guiInfo.Tracks;i++ )
0ba85cad4c7e Add audio CD playback support to the X11/GTK GUI.
ib
parents: 34333
diff changeset
454 {
36694
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
455 snprintf( tmp,32,MSGTR_GUI_TitleNN,i );
34387
0ba85cad4c7e Add audio CD playback support to the X11/GTK GUI.
ib
parents: 34333
diff changeset
456 //AddMenuItem( CDTitleMenu,tmp,( i << 16 ) + ivSetCDTrack );
34422
b1f2949ca18d Use empty1px.xpm instead of empty.xpm for check item (and similar) menus.
ib
parents: 34421
diff changeset
457 AddMenuCheckItem(window1, (const char*)empty1px_xpm, CDTitleMenu,tmp, guiInfo.Track == i, ( i << 16 ) + ivSetCDTrack );
34387
0ba85cad4c7e Add audio CD playback support to the X11/GTK GUI.
ib
parents: 34333
diff changeset
458 }
0ba85cad4c7e Add audio CD playback support to the X11/GTK GUI.
ib
parents: 34333
diff changeset
459 }
0ba85cad4c7e Add audio CD playback support to the X11/GTK GUI.
ib
parents: 34333
diff changeset
460 else
0ba85cad4c7e Add audio CD playback support to the X11/GTK GUI.
ib
parents: 34333
diff changeset
461 {
36694
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
462 MenuItem=AddMenuItem( window1, (const char*)empty1px_xpm, CDTitleMenu,MSGTR_GUI__none_,evNone );
34387
0ba85cad4c7e Add audio CD playback support to the X11/GTK GUI.
ib
parents: 34333
diff changeset
463 gtk_widget_set_sensitive( MenuItem,FALSE );
0ba85cad4c7e Add audio CD playback support to the X11/GTK GUI.
ib
parents: 34333
diff changeset
464 }
0ba85cad4c7e Add audio CD playback support to the X11/GTK GUI.
ib
parents: 34333
diff changeset
465 #endif
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
466 #ifdef CONFIG_VCD
36694
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
467 AddMenuItem( window1, (const char*)playvcd_xpm, SubMenu,MSGTR_GUI_VCD, evPlayVCD );
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
468 VCDSubMenu=AddSubMenu( window1, (const char*)vcd_xpm, Menu,MSGTR_GUI_VCD );
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
469 AddMenuItem( window1, (const char*)playvcd_xpm, VCDSubMenu,MSGTR_GUI_Play,evPlayVCD );
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
470 AddSeparator( VCDSubMenu );
36694
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
471 VCDTitleMenu=AddSubMenu( window1, (const char*)title_xpm, VCDSubMenu,MSGTR_GUI_Titles );
34420
0b31cf6cec25 Fix bug in CD / VCD / DVD related menus.
ib
parents: 34419
diff changeset
472 if ( guiInfo.Tracks && ( guiInfo.StreamType == STREAMTYPE_VCD ) )
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
473 {
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
474 char tmp[32]; int i;
33876
4789b8eed97e Get rid of a bunch of needless or redundant guiInfo members.
ib
parents: 33874
diff changeset
475 for ( i=1;i < guiInfo.Tracks;i++ )
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
476 {
36694
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
477 snprintf( tmp,32,MSGTR_GUI_TitleNN,i );
34333
e8e4e6f9b7ac Change prefix for internal events from ev to iv.
ib
parents: 34324
diff changeset
478 //AddMenuItem( VCDTitleMenu,tmp,( i << 16 ) + ivSetVCDTrack );
34422
b1f2949ca18d Use empty1px.xpm instead of empty.xpm for check item (and similar) menus.
ib
parents: 34421
diff changeset
479 AddMenuCheckItem(window1, (const char*)empty1px_xpm, VCDTitleMenu,tmp, guiInfo.Track == i + 1, ( ( i + 1 ) << 16 ) + ivSetVCDTrack );
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
480 }
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
481 }
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
482 else
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
483 {
36694
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
484 MenuItem=AddMenuItem( window1, (const char*)empty1px_xpm, VCDTitleMenu,MSGTR_GUI__none_,evNone );
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
485 gtk_widget_set_sensitive( MenuItem,FALSE );
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
486 }
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
487 #endif
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
488 #ifdef CONFIG_DVDREAD
36694
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
489 AddMenuItem( window1, (const char*)playdvd_xpm, SubMenu,MSGTR_GUI_DVD, evPlayDVD );
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
490 DVDSubMenu=AddSubMenu( window1, (const char*)dvd_xpm, Menu,MSGTR_GUI_DVD );
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
491 AddMenuItem( window1, (const char*)playdvd_xpm, DVDSubMenu,MSGTR_GUI_Play" ", evPlayDVD );
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
492 // AddMenuItem( DVDSubMenu,MSGTR_MENU_ShowDVDMenu, evNone );
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
493 AddSeparator( DVDSubMenu );
36694
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
494 DVDTitleMenu=AddSubMenu( window1, (const char*)title_xpm, DVDSubMenu,MSGTR_GUI_Titles );
34420
0b31cf6cec25 Fix bug in CD / VCD / DVD related menus.
ib
parents: 34419
diff changeset
495 if ( guiInfo.Tracks && ( guiInfo.StreamType == STREAMTYPE_DVD ) )
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
496 {
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
497 char tmp[32]; int i;
33876
4789b8eed97e Get rid of a bunch of needless or redundant guiInfo members.
ib
parents: 33874
diff changeset
498 for ( i=1 ; i<= guiInfo.Tracks;i++ )
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
499 {
36694
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
500 snprintf( tmp,32,MSGTR_GUI_TitleNN,i);
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
501 AddMenuCheckItem( window1, (const char*)empty1px_xpm, DVDTitleMenu,tmp,
33876
4789b8eed97e Get rid of a bunch of needless or redundant guiInfo members.
ib
parents: 33874
diff changeset
502 guiInfo.Track == i,
34333
e8e4e6f9b7ac Change prefix for internal events from ev to iv.
ib
parents: 34324
diff changeset
503 (i << 16) + ivSetDVDTitle );
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
504 }
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
505 }
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
506 else
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
507 {
36694
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
508 MenuItem=AddMenuItem( window1, (const char*)empty1px_xpm, DVDTitleMenu,MSGTR_GUI__none_,evNone );
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
509 gtk_widget_set_sensitive( MenuItem,FALSE );
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
510 }
36694
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
511 DVDChapterMenu=AddSubMenu( window1, (const char*)chapter_xpm, DVDSubMenu,MSGTR_GUI_Chapters );
34420
0b31cf6cec25 Fix bug in CD / VCD / DVD related menus.
ib
parents: 34419
diff changeset
512 if ( guiInfo.Chapters && ( guiInfo.StreamType == STREAMTYPE_DVD ) )
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
513 {
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
514 char tmp[32]; int i;
33876
4789b8eed97e Get rid of a bunch of needless or redundant guiInfo members.
ib
parents: 33874
diff changeset
515 for ( i=1;i <= guiInfo.Chapters;i++ )
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
516 {
36694
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
517 snprintf( tmp,32,MSGTR_GUI_ChapterNN,i );
33876
4789b8eed97e Get rid of a bunch of needless or redundant guiInfo members.
ib
parents: 33874
diff changeset
518 AddMenuCheckItem( window1, (const char*)empty1px_xpm, DVDChapterMenu,tmp,guiInfo.Chapter == i,
34333
e8e4e6f9b7ac Change prefix for internal events from ev to iv.
ib
parents: 34324
diff changeset
519 ( i << 16 ) + ivSetDVDChapter );
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
520 }
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
521 }
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
522 else
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
523 {
36694
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
524 MenuItem=AddMenuItem( window1, (const char*)empty1px_xpm, DVDChapterMenu,MSGTR_GUI__none_,evNone );
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
525 gtk_widget_set_sensitive( MenuItem,FALSE );
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
526 }
36694
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
527 DVDAudioLanguageMenu=AddSubMenu( window1, (const char*)audio_xpm, DVDSubMenu,MSGTR_GUI_AudioTracks );
36700
9f19f1bd34eb Simplify code.
ib
parents: 36699
diff changeset
528 if ( guiInfo.AudioStreams && demuxer && ( guiInfo.StreamType == STREAMTYPE_DVD ) )
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
529 {
36700
9f19f1bd34eb Simplify code.
ib
parents: 36699
diff changeset
530 char tmp[64]; int i;
33902
dd0e5dc6ebbf Add guiDVDStruct members to guiInfo.
ib
parents: 33901
diff changeset
531 for ( i=0;i < guiInfo.AudioStreams;i++ )
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
532 {
33902
dd0e5dc6ebbf Add guiDVDStruct members to guiInfo.
ib
parents: 33901
diff changeset
533 snprintf( tmp,64,"%s - %s %s",GetLanguage( guiInfo.AudioStream[i].language ),
dd0e5dc6ebbf Add guiDVDStruct members to guiInfo.
ib
parents: 33901
diff changeset
534 ChannelTypes[ guiInfo.AudioStream[i].type ],
dd0e5dc6ebbf Add guiDVDStruct members to guiInfo.
ib
parents: 33901
diff changeset
535 ChannelNumbers[ guiInfo.AudioStream[i].channels ] );
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
536 AddMenuCheckItem( window1, (const char*)dolby_xpm, DVDAudioLanguageMenu,tmp,
36700
9f19f1bd34eb Simplify code.
ib
parents: 36699
diff changeset
537 demuxer->audio->id == guiInfo.AudioStream[i].id,
34333
e8e4e6f9b7ac Change prefix for internal events from ev to iv.
ib
parents: 34324
diff changeset
538 ( guiInfo.AudioStream[i].id << 16 ) + ivSetDVDAudio );
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
539 }
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
540 }
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
541 else
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
542 {
36694
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
543 MenuItem=AddMenuItem( window1, (const char*)empty1px_xpm, DVDAudioLanguageMenu,MSGTR_GUI__none_,evNone );
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
544 gtk_widget_set_sensitive( MenuItem,FALSE );
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
545 }
36694
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
546 DVDSubtitleLanguageMenu=AddSubMenu( window1, (const char*)subtitle_xpm, DVDSubMenu,MSGTR_GUI_Subtitles );
34420
0b31cf6cec25 Fix bug in CD / VCD / DVD related menus.
ib
parents: 34419
diff changeset
547 if ( guiInfo.Subtitles && ( guiInfo.StreamType == STREAMTYPE_DVD ) )
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
548 {
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
549 char tmp[64]; int i;
36694
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
550 AddMenuItem( window1, (const char*)empty1px_xpm, DVDSubtitleLanguageMenu,MSGTR_GUI__none_,( (unsigned short)-1 << 16 ) + ivSetDVDSubtitle );
33902
dd0e5dc6ebbf Add guiDVDStruct members to guiInfo.
ib
parents: 33901
diff changeset
551 for ( i=0;i < guiInfo.Subtitles;i++ )
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
552 {
33902
dd0e5dc6ebbf Add guiDVDStruct members to guiInfo.
ib
parents: 33901
diff changeset
553 av_strlcpy( tmp,GetLanguage( guiInfo.Subtitle[i].language ),sizeof(tmp) );
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
554 AddMenuCheckItem( window1, (const char*)empty1px_xpm, DVDSubtitleLanguageMenu,tmp,
33902
dd0e5dc6ebbf Add guiDVDStruct members to guiInfo.
ib
parents: 33901
diff changeset
555 dvdsub_id == guiInfo.Subtitle[i].id,
34333
e8e4e6f9b7ac Change prefix for internal events from ev to iv.
ib
parents: 34324
diff changeset
556 ( guiInfo.Subtitle[i].id << 16 ) + ivSetDVDSubtitle );
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
557 }
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
558 }
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
559 else
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
560 {
36694
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
561 MenuItem=AddMenuItem( window1, (const char*)empty1px_xpm, DVDSubtitleLanguageMenu,MSGTR_GUI__none_,evNone );
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
562 gtk_widget_set_sensitive( MenuItem,FALSE );
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
563 }
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
564 #endif
36694
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
565 AddMenuItem( window1, (const char*)url_xpm, SubMenu,MSGTR_GUI_URL"...", evLoadURL );
36429
28ea255e40ce Add support for TV/DVB to the GUI.
ib
parents: 36316
diff changeset
566 #ifdef CONFIG_TV
36694
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
567 AddMenuItem( window1, (const char*)tv_xpm, SubMenu,MSGTR_GUI_TV, evPlayTV );
36429
28ea255e40ce Add support for TV/DVB to the GUI.
ib
parents: 36316
diff changeset
568 #endif
36663
ece867ba2a75 Move up entry "external audio" in the context menu.
ib
parents: 36623
diff changeset
569 AddSeparator( SubMenu );
36694
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
570 AddMenuItem( window1, (const char*)loadeaf_xpm, SubMenu,MSGTR_GUI_AudioTrack"...", evLoadAudioFile );
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
571 AddMenuItem( window1, (const char*)sub_xpm, SubMenu,MSGTR_GUI_Subtitle"... ", evLoadSubtitle );
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
572 AddMenuItem( window1, (const char*)nosub_xpm, SubMenu,MSGTR_GUI_DropSubtitle,evDropSubtitle );
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
573 SubMenu=AddSubMenu(window1, (const char*)play_xpm, Menu,MSGTR_GUI_Playback );
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
574 AddMenuItem( window1, (const char*)play_xpm, SubMenu,MSGTR_GUI_Play" ", evPlay );
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
575 AddMenuItem( window1, (const char*)pause_xpm, SubMenu,MSGTR_GUI_Pause, evPause );
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
576 AddMenuItem( window1, (const char*)stop_xpm, SubMenu,MSGTR_GUI_Stop, evStop );
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
577 AddMenuItem( window1, (const char*)next_xpm, SubMenu,MSGTR_GUI_Next, evNext );
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
578 AddMenuItem( window1, (const char*)prev_xpm, SubMenu,MSGTR_GUI_Previous, evPrev );
34419
a56707da37cd Move CD / VCD / DVD related menu code.
ib
parents: 34387
diff changeset
579 // AddSeparator( SubMenu );
a56707da37cd Move CD / VCD / DVD related menu code.
ib
parents: 34387
diff changeset
580 // AddMenuItem( SubMenu,"Back 10 sec", evBackward10sec );
a56707da37cd Move CD / VCD / DVD related menu code.
ib
parents: 34387
diff changeset
581 // AddMenuItem( SubMenu,"Fwd 10 sec", evForward10sec );
a56707da37cd Move CD / VCD / DVD related menu code.
ib
parents: 34387
diff changeset
582 // AddMenuItem( SubMenu,"Back 1 min", evBackward1min );
a56707da37cd Move CD / VCD / DVD related menu code.
ib
parents: 34387
diff changeset
583 // AddMenuItem( SubMenu,"Fwd 1 min", evForward1min );
a56707da37cd Move CD / VCD / DVD related menu code.
ib
parents: 34387
diff changeset
584 // SubMenu=AddSubMenu( Menu,MSGTR_MENU_Size );
36694
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
585 // AddMenuItem( SubMenu,MSGTR_GUI_SizeNormal" ", evNormalSize );
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
586 // AddMenuItem( SubMenu,MSGTR_GUI_SizeDouble, evDoubleSize );
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
587 // AddMenuItem( SubMenu,MSGTR_GUI_SizeFullscreen, evFullScreen + ( True << 16 ) );
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
588
36261
ca1d4a7bb751 Disable aspect ratio menu in the absence of video playback.
ib
parents: 36029
diff changeset
589 if ( guiInfo.VideoWindow )
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
590 {
36273
55cac32d68c2 Add check marks to the video aspect ratio menu items.
ib
parents: 36261
diff changeset
591 int a11 = False, a169 = False, a43 = False, a235 = False;
36622
b9dc795036a2 Group video and audio related entries in context menu together.
ib
parents: 36621
diff changeset
592 AddSeparator( Menu );
36316
139f2b064ef9 Don't subsequently calculate original_aspect from last movie_aspect.
ib
parents: 36297
diff changeset
593 if (movie_aspect == -1.0f) a11 = True;
36273
55cac32d68c2 Add check marks to the video aspect ratio menu items.
ib
parents: 36261
diff changeset
594 else
55cac32d68c2 Add check marks to the video aspect ratio menu items.
ib
parents: 36261
diff changeset
595 {
55cac32d68c2 Add check marks to the video aspect ratio menu items.
ib
parents: 36261
diff changeset
596 a169 = (FFABS(movie_aspect - 16.0f / 9.0f) <= 0.01f);
55cac32d68c2 Add check marks to the video aspect ratio menu items.
ib
parents: 36261
diff changeset
597 a43 = (FFABS(movie_aspect - 4.0f / 3.0f) <= 0.01f);
36276
f7ef757c95c0 Be more pedantic about type of the constant.
ib
parents: 36273
diff changeset
598 a235 = (FFABS(movie_aspect - 2.35f) <= 0.01f);
36273
55cac32d68c2 Add check marks to the video aspect ratio menu items.
ib
parents: 36261
diff changeset
599 }
55cac32d68c2 Add check marks to the video aspect ratio menu items.
ib
parents: 36261
diff changeset
600
36694
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
601 AspectMenu=AddSubMenu( window1, (const char*)aspect_xpm, Menu,MSGTR_GUI_AspectRatio );
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
602 H=AddMenuCheckItem( window1, (const char*)aspect11_xpm, AspectMenu,MSGTR_GUI_Original, a11, evSetAspect + ( 1 << 16 ) );
36273
55cac32d68c2 Add check marks to the video aspect ratio menu items.
ib
parents: 36261
diff changeset
603 N=AddMenuCheckItem( window1, (const char*)aspect169_xpm, AspectMenu,"16:9", a169, evSetAspect + ( 2 << 16 ) );
55cac32d68c2 Add check marks to the video aspect ratio menu items.
ib
parents: 36261
diff changeset
604 D=AddMenuCheckItem( window1, (const char*)aspect43_xpm, AspectMenu,"4:3", a43, evSetAspect + ( 3 << 16 ) );
36694
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
605 F=AddMenuCheckItem( window1, (const char*)aspect235_xpm, AspectMenu,MSGTR_GUI_235To1, a235, evSetAspect + ( 4 << 16 ) );
36261
ca1d4a7bb751 Disable aspect ratio menu in the absence of video playback.
ib
parents: 36029
diff changeset
606
ca1d4a7bb751 Disable aspect ratio menu in the absence of video playback.
ib
parents: 36029
diff changeset
607 if ( !guiInfo.Playing )
ca1d4a7bb751 Disable aspect ratio menu in the absence of video playback.
ib
parents: 36029
diff changeset
608 {
ca1d4a7bb751 Disable aspect ratio menu in the absence of video playback.
ib
parents: 36029
diff changeset
609 gtk_widget_set_sensitive( H,FALSE );
ca1d4a7bb751 Disable aspect ratio menu in the absence of video playback.
ib
parents: 36029
diff changeset
610 gtk_widget_set_sensitive( N,FALSE );
ca1d4a7bb751 Disable aspect ratio menu in the absence of video playback.
ib
parents: 36029
diff changeset
611 gtk_widget_set_sensitive( D,FALSE );
ca1d4a7bb751 Disable aspect ratio menu in the absence of video playback.
ib
parents: 36029
diff changeset
612 gtk_widget_set_sensitive( F,FALSE );
ca1d4a7bb751 Disable aspect ratio menu in the absence of video playback.
ib
parents: 36029
diff changeset
613 }
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
614 }
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
615
36622
b9dc795036a2 Group video and audio related entries in context menu together.
ib
parents: 36621
diff changeset
616 if ( guiInfo.VideoWindow )
b9dc795036a2 Group video and audio related entries in context menu together.
ib
parents: 36621
diff changeset
617 {
b9dc795036a2 Group video and audio related entries in context menu together.
ib
parents: 36621
diff changeset
618 int b1 = False, b2 = False, b_half = False;
b9dc795036a2 Group video and audio related entries in context menu together.
ib
parents: 36621
diff changeset
619
b9dc795036a2 Group video and audio related entries in context menu together.
ib
parents: 36621
diff changeset
620 if ( !guiApp.videoWindow.isFullScreen && guiInfo.Playing )
b9dc795036a2 Group video and audio related entries in context menu together.
ib
parents: 36621
diff changeset
621 {
b9dc795036a2 Group video and audio related entries in context menu together.
ib
parents: 36621
diff changeset
622 if ( ( guiApp.videoWindow.Width == guiInfo.VideoWidth * 2 )&&
b9dc795036a2 Group video and audio related entries in context menu together.
ib
parents: 36621
diff changeset
623 ( guiApp.videoWindow.Height == guiInfo.VideoHeight * 2 ) ) b2=True;
b9dc795036a2 Group video and audio related entries in context menu together.
ib
parents: 36621
diff changeset
624 else if ( ( guiApp.videoWindow.Width == guiInfo.VideoWidth / 2 ) &&
b9dc795036a2 Group video and audio related entries in context menu together.
ib
parents: 36621
diff changeset
625 ( guiApp.videoWindow.Height == guiInfo.VideoHeight / 2 ) ) b_half=True;
b9dc795036a2 Group video and audio related entries in context menu together.
ib
parents: 36621
diff changeset
626 else b1=( guiApp.videoWindow.Width == guiInfo.VideoWidth && guiApp.videoWindow.Height == guiInfo.VideoHeight );
b9dc795036a2 Group video and audio related entries in context menu together.
ib
parents: 36621
diff changeset
627 } else b1=!guiApp.videoWindow.isFullScreen;
36694
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
628 F=AddMenuCheckItem( window1, (const char*)full_xpm, Menu,MSGTR_GUI_SizeFullscreen,guiApp.videoWindow.isFullScreen,evFullScreen + ( True << 16 ) );
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
629 D=AddMenuCheckItem( window1, (const char*)double_xpm, Menu,MSGTR_GUI_SizeDouble,b2,evDoubleSize );
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
630 N=AddMenuCheckItem( window1, (const char*)normal_xpm, Menu,MSGTR_GUI_SizeNormal" ",b1,evNormalSize );
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
631 H=AddMenuCheckItem( window1, (const char*)half_xpm, Menu,MSGTR_GUI_SizeHalf,b_half,evHalfSize );
36622
b9dc795036a2 Group video and audio related entries in context menu together.
ib
parents: 36621
diff changeset
632 if ( !guiInfo.Playing )
b9dc795036a2 Group video and audio related entries in context menu together.
ib
parents: 36621
diff changeset
633 {
b9dc795036a2 Group video and audio related entries in context menu together.
ib
parents: 36621
diff changeset
634 gtk_widget_set_sensitive( H,FALSE );
b9dc795036a2 Group video and audio related entries in context menu together.
ib
parents: 36621
diff changeset
635 gtk_widget_set_sensitive( N,FALSE );
b9dc795036a2 Group video and audio related entries in context menu together.
ib
parents: 36621
diff changeset
636 gtk_widget_set_sensitive( D,FALSE );
b9dc795036a2 Group video and audio related entries in context menu together.
ib
parents: 36621
diff changeset
637 gtk_widget_set_sensitive( F,FALSE );
b9dc795036a2 Group video and audio related entries in context menu together.
ib
parents: 36621
diff changeset
638 }
b9dc795036a2 Group video and audio related entries in context menu together.
ib
parents: 36621
diff changeset
639 }
b9dc795036a2 Group video and audio related entries in context menu together.
ib
parents: 36621
diff changeset
640
b9dc795036a2 Group video and audio related entries in context menu together.
ib
parents: 36621
diff changeset
641 AddSeparator( Menu );
36694
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
642 MenuItem=AddMenuCheckItem( window1, (const char*)sound_xpm, Menu,MSGTR_GUI_Mute,mixer->muted,evMute );
36622
b9dc795036a2 Group video and audio related entries in context menu together.
ib
parents: 36621
diff changeset
643 if ( !guiInfo.AudioChannels ) gtk_widget_set_sensitive( MenuItem,FALSE );
b9dc795036a2 Group video and audio related entries in context menu together.
ib
parents: 36621
diff changeset
644
33657
c92f23eac7a4 Remove guiGetEvent type guiSetDemuxer.
ib
parents: 33655
diff changeset
645 if ( guiInfo.Playing && demuxer && guiInfo.StreamType != STREAMTYPE_DVD )
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
646 {
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
647 int i,c = 0;
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
648
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
649 for ( i=0;i < MAX_A_STREAMS;i++ )
33657
c92f23eac7a4 Remove guiGetEvent type guiSetDemuxer.
ib
parents: 33655
diff changeset
650 if ( demuxer->a_streams[i] ) c++;
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
651
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
652 if ( c > 1 )
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
653 {
36694
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
654 SubMenu=AddSubMenu( window1, (const char*)audio_xpm, Menu,MSGTR_GUI_AudioTracks );
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
655 for ( i=0;i < MAX_A_STREAMS;i++ )
33657
c92f23eac7a4 Remove guiGetEvent type guiSetDemuxer.
ib
parents: 33655
diff changeset
656 if ( demuxer->a_streams[i] )
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
657 {
33657
c92f23eac7a4 Remove guiGetEvent type guiSetDemuxer.
ib
parents: 33655
diff changeset
658 int aid = ((sh_audio_t *)demuxer->a_streams[i])->aid;
36699
51fccd9e0dc7 Simplify code.
ib
parents: 36694
diff changeset
659 int selected_id = (audio_id == aid || (audio_id == -1 && aid == demuxer_default_audio_track(demuxer)));
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
660 char tmp[32];
36694
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
661 snprintf( tmp,32,MSGTR_GUI_TrackN,aid );
34555
da67e2df97be Emphasize the default audio track in the selection list.
ib
parents: 34479
diff changeset
662 AddMenuCheckItem( window1, (const char*)empty1px_xpm, SubMenu,tmp,selected_id,( aid << 16 ) + ivSetAudio );
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
663 }
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
664 }
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
665
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
666 for ( c=0,i=0;i < MAX_V_STREAMS;i++ )
33657
c92f23eac7a4 Remove guiGetEvent type guiSetDemuxer.
ib
parents: 33655
diff changeset
667 if ( demuxer->v_streams[i] ) c++;
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
668
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
669 if ( c > 1 )
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
670 {
36694
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
671 SubMenu=AddSubMenu( window1, (const char*)video_xpm, Menu,MSGTR_GUI_VideoTracks );
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
672 for ( i=0;i < MAX_V_STREAMS;i++ )
33657
c92f23eac7a4 Remove guiGetEvent type guiSetDemuxer.
ib
parents: 33655
diff changeset
673 if ( demuxer->v_streams[i] )
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
674 {
33657
c92f23eac7a4 Remove guiGetEvent type guiSetDemuxer.
ib
parents: 33655
diff changeset
675 int vid = ((sh_video_t *)demuxer->v_streams[i])->vid;
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
676 char tmp[32];
36699
51fccd9e0dc7 Simplify code.
ib
parents: 36694
diff changeset
677 int selected_id = (video_id == vid || (video_id == -1 && vid == demuxer_default_video_track(demuxer)));
36694
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
678 snprintf( tmp,32,MSGTR_GUI_TrackN,vid );
36683
acb4a92aba16 Improve emphasizing of the current video track.
ib
parents: 36672
diff changeset
679 AddMenuCheckItem( window1, (const char*)empty1px_xpm, SubMenu,tmp,selected_id,( vid << 16 ) + ivSetVideo );
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
680 }
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
681 }
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
682 }
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
683
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
684 /* cheap subtitle switching for non-DVD streams */
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
685 if ( global_sub_size && guiInfo.StreamType != STREAMTYPE_DVD )
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
686 {
36458
4634a3085efc Add mpctx_get_global_sub_pos().
ib
parents: 36429
diff changeset
687 int pos, i;
4634a3085efc Add mpctx_get_global_sub_pos().
ib
parents: 36429
diff changeset
688 pos = mpctx_get_global_sub_pos(guiInfo.mpcontext);
36694
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
689 SubMenu=AddSubMenu( window1, (const char*)subtitle_xpm, Menu, MSGTR_GUI_Subtitles );
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
690 AddMenuCheckItem( window1, (const char*)empty1px_xpm, SubMenu, MSGTR_GUI__none_, pos == -1, (-1 << 16) + ivSetSubtitle );
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
691 for ( i=0;i < global_sub_size;i++ )
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
692 {
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
693 char tmp[32];
36694
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
694 snprintf( tmp, 32, MSGTR_GUI_TrackN, i );
36458
4634a3085efc Add mpctx_get_global_sub_pos().
ib
parents: 36429
diff changeset
695 AddMenuCheckItem( window1,(const char*)empty1px_xpm,SubMenu,tmp,pos == i,( i << 16 ) + ivSetSubtitle );
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
696 }
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
697 }
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
698
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
699 AddSeparator( Menu );
36694
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
700 AddMenuItem( window1, (const char*)equalizer_xpm, Menu,MSGTR_GUI_Equalizer, evEqualizer );
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
701 AddMenuItem( window1, (const char*)playlist_xpm, Menu,MSGTR_GUI_Playlist, evPlaylist );
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
702 AddMenuItem( window1, (const char*)skin_xpm, Menu,MSGTR_GUI_SkinBrowser, evSkinBrowser );
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
703 AddMenuItem( window1, (const char*)prefs_xpm, Menu,MSGTR_GUI_Preferences, evPreferences );
36620
e79d56d7d9d3 Relocate the video size entries in the context menu.
ib
parents: 36619
diff changeset
704
e79d56d7d9d3 Relocate the video size entries in the context menu.
ib
parents: 36619
diff changeset
705 AddSeparator( Menu );
36694
eed2fb870f43 Rename symbolic constants of GUI help message texts.
ib
parents: 36683
diff changeset
706 AddMenuItem( window1, (const char*)exit_xpm, Menu,MSGTR_GUI_Quit, evExit );
33572
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
707
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
708 return Menu;
d9b805602aa1 Rename some gtk files.
ib
parents:
diff changeset
709 }