6626
|
1
|
|
2 #include <stdlib.h>
|
|
3 #include <stdio.h>
|
|
4 #include <sys/types.h>
|
|
5 #include <sys/stat.h>
|
|
6 #include <unistd.h>
|
|
7 #include <string.h>
|
|
8
|
|
9 #include <gdk/gdkkeysyms.h>
|
|
10 #include <gtk/gtk.h>
|
|
11
|
6627
|
12 #include "../../events.h"
|
6651
|
13 #include "../../help_mp.h"
|
6627
|
14 #include "../../../config.h"
|
|
15 #include "../../../help_mp.h"
|
|
16 #include "../../../mplayer.h"
|
|
17 #include "../../../libao2/eq.h"
|
6755
|
18 #include "../../../libvo/video_out.h"
|
6627
|
19 #include "../widgets.h"
|
|
20 #include "../mplayer.h"
|
|
21
|
6626
|
22 #include "eq.h"
|
|
23
|
6627
|
24 GtkWidget * Equalizer;
|
|
25
|
|
26 static GtkWidget * Notebook;
|
6626
|
27 static GtkWidget * ChannelsList;
|
|
28 static GtkWidget * VContrast, * VBrightness, * VHue, * VSaturation;
|
|
29 static GtkAdjustment * VContrastadj, * VBrightnessadj, * VHueadj, * VSaturationadj;
|
6651
|
30 static GtkWidget * Ok, * Clear, * Config;
|
6626
|
31 static GtkWidget * A3125, * A125, * A6250, * A250, * A500, * A1000, * A2000, * A4000, * A8000, * A16000;
|
|
32 static GtkAdjustment * A3125adj, * A125adj, * A6250adj, * A250adj, * A500adj, * A1000adj, * A2000adj, * A4000adj, * A8000adj, * A16000adj;
|
|
33
|
|
34 static int Channel = -1;
|
6627
|
35 static int gtkVEqualizer = 0;
|
6651
|
36 static int gtkVEquConfig = 0;
|
|
37
|
|
38 // ---
|
6627
|
39
|
|
40 int gtkEnableAudioEqualizer = 1;
|
|
41 int gtkEnableVideoEqualizer = 1;
|
|
42
|
6651
|
43 char * gtkEquChannel1 = NULL;
|
|
44 char * gtkEquChannel2 = NULL;
|
|
45 char * gtkEquChannel3 = NULL;
|
|
46 char * gtkEquChannel4 = NULL;
|
|
47 char * gtkEquChannel5 = NULL;
|
|
48 char * gtkEquChannel6 = NULL;
|
|
49
|
|
50 // ---
|
|
51
|
|
52 void ShowEquConfig( void );
|
|
53 void HideEquConfig( void );
|
|
54
|
6627
|
55 static void eqSetBands( int channel )
|
|
56 {
|
|
57 if ( channel < 0 ) channel=0;
|
|
58 gtk_adjustment_set_value( A3125adj,0.0f - gtkEquChannels[channel][0] );
|
|
59 gtk_adjustment_set_value( A6250adj,0.0f - gtkEquChannels[channel][1] );
|
|
60 gtk_adjustment_set_value( A125adj,0.0f - gtkEquChannels[channel][2] );
|
|
61 gtk_adjustment_set_value( A250adj,0.0f - gtkEquChannels[channel][3] );
|
|
62 gtk_adjustment_set_value( A500adj,0.0f - gtkEquChannels[channel][4] );
|
|
63 gtk_adjustment_set_value( A1000adj,0.0f - gtkEquChannels[channel][5] );
|
|
64 gtk_adjustment_set_value( A2000adj,0.0f - gtkEquChannels[channel][6] );
|
|
65 gtk_adjustment_set_value( A4000adj,0.0f - gtkEquChannels[channel][7] );
|
|
66 gtk_adjustment_set_value( A8000adj,0.0f - gtkEquChannels[channel][8] );
|
|
67 gtk_adjustment_set_value( A16000adj,0.0f - gtkEquChannels[channel][9] );
|
6755
|
68
|
|
69 gtk_adjustment_set_value( VContrastadj,(float)vo_gamma_contrast );
|
|
70 gtk_adjustment_set_value( VBrightnessadj,(float)vo_gamma_brightness );
|
|
71 gtk_adjustment_set_value( VHueadj,(float)vo_gamma_hue );
|
|
72 gtk_adjustment_set_value( VSaturationadj,(float)vo_gamma_saturation );
|
6627
|
73 }
|
|
74
|
6651
|
75 static void eqSetChannelNames( void )
|
|
76 {
|
|
77 gchar * str[2];
|
|
78 gtk_clist_clear( GTK_CLIST( ChannelsList ) );
|
|
79 str[1]="";
|
|
80 str[0]=MSGTR_EQU_All;
|
|
81 gtk_clist_append( GTK_CLIST( ChannelsList ) ,str);
|
|
82 if ( guiIntfStruct.AudioType > 1 )
|
|
83 {
|
|
84 str[0]=gtkEquChannel1; gtk_clist_append( GTK_CLIST( ChannelsList ) ,str);
|
|
85 str[0]=gtkEquChannel2; gtk_clist_append( GTK_CLIST( ChannelsList ) ,str);
|
|
86 }
|
|
87 if ( guiIntfStruct.AudioType > 2 )
|
|
88 {
|
|
89 str[0]=gtkEquChannel3; gtk_clist_append( GTK_CLIST( ChannelsList ) ,str);
|
|
90 str[0]=gtkEquChannel4; gtk_clist_append( GTK_CLIST( ChannelsList ) ,str);
|
|
91 }
|
|
92 if ( guiIntfStruct.AudioType > 4 )
|
|
93 {
|
|
94 str[0]=gtkEquChannel5; gtk_clist_append( GTK_CLIST( ChannelsList ) ,str);
|
|
95 str[0]=gtkEquChannel6; gtk_clist_append( GTK_CLIST( ChannelsList ) ,str);
|
|
96 }
|
6755
|
97 gtk_clist_select_row( GTK_CLIST( ChannelsList ),0,0 );
|
6651
|
98 }
|
|
99
|
6627
|
100 void ShowEqualizer( void )
|
|
101 {
|
|
102 if ( gtkVEqualizer ) gtkActive( Equalizer );
|
|
103 else Equalizer=create_Equalizer();
|
|
104
|
6651
|
105 if ( !gtkEquChannel1 ) gtkEquChannel1=strdup( MSGTR_EQU_Front_Right );
|
|
106 if ( !gtkEquChannel2 ) gtkEquChannel2=strdup( MSGTR_EQU_Front_Left );
|
|
107 if ( !gtkEquChannel3 ) gtkEquChannel3=strdup( MSGTR_EQU_Back_Right );
|
|
108 if ( !gtkEquChannel4 ) gtkEquChannel4=strdup( MSGTR_EQU_Back_Left );
|
|
109 if ( !gtkEquChannel5 ) gtkEquChannel5=strdup( MSGTR_EQU_Center );
|
|
110 if ( !gtkEquChannel6 ) gtkEquChannel6=strdup( MSGTR_EQU_Bass );
|
6627
|
111
|
6651
|
112 eqSetChannelNames();
|
|
113
|
6755
|
114 VContrastadj->value=(float)vo_gamma_contrast;
|
|
115 VBrightnessadj->value=(float)vo_gamma_brightness;
|
|
116 VHueadj->value=(float)vo_gamma_hue;
|
|
117 VSaturationadj->value=(float)vo_gamma_saturation;
|
6627
|
118
|
6651
|
119 if ( !guiIntfStruct.Playing && gtkEnableVideoEqualizer )
|
|
120 {
|
|
121 gtk_widget_set_sensitive( VContrast,FALSE );
|
|
122 gtk_widget_set_sensitive( VBrightness,FALSE );
|
|
123 gtk_widget_set_sensitive( VHue,FALSE );
|
|
124 gtk_widget_set_sensitive( VSaturation,FALSE );
|
|
125 }
|
|
126 Channel=0;
|
|
127 eqSetBands( 0 );
|
|
128 if ( !guiIntfStruct.Playing && gtkEnableAudioEqualizer )
|
|
129 {
|
|
130 gtk_widget_set_sensitive( ChannelsList,FALSE );
|
|
131 gtk_widget_set_sensitive( A3125,FALSE );
|
|
132 gtk_widget_set_sensitive( A125,FALSE );
|
|
133 gtk_widget_set_sensitive( A6250,FALSE );
|
|
134 gtk_widget_set_sensitive( A250,FALSE );
|
|
135 gtk_widget_set_sensitive( A500,FALSE );
|
|
136 gtk_widget_set_sensitive( A1000,FALSE );
|
|
137 gtk_widget_set_sensitive( A2000,FALSE );
|
|
138 gtk_widget_set_sensitive( A4000,FALSE );
|
|
139 gtk_widget_set_sensitive( A8000,FALSE );
|
|
140 gtk_widget_set_sensitive( A16000,FALSE );
|
6627
|
141 }
|
|
142
|
6755
|
143 if ( gtk_notebook_get_current_page( GTK_NOTEBOOK( Notebook ) ) == 0 ) gtk_widget_show( Config );
|
6627
|
144 gtk_widget_show( Equalizer );
|
6755
|
145 gtkVisible++;
|
6627
|
146 }
|
6626
|
147
|
|
148 void HideEqualizer( void )
|
6651
|
149 {
|
6755
|
150 if ( !gtkVEqualizer ) return;
|
|
151 gtkVEqualizer=0; gtkVisible--;
|
6651
|
152 gtk_widget_hide( Equalizer );
|
|
153 gtk_widget_destroy( Equalizer );
|
|
154 if ( gtkVEquConfig ) HideEquConfig();
|
|
155 }
|
6626
|
156
|
6627
|
157 static gboolean eqHScaleMotion( GtkWidget * widget,GdkEventMotion * event,gpointer user_data )
|
6626
|
158 {
|
6627
|
159 equalizer_t eq;
|
6626
|
160 switch ( (int)user_data )
|
|
161 {
|
6627
|
162 case 0: eq.gain=A3125adj->value; break;
|
|
163 case 1: eq.gain=A6250adj->value; break;
|
|
164 case 2: eq.gain=A125adj->value; break;
|
|
165 case 3: eq.gain=A250adj->value; break;
|
|
166 case 4: eq.gain=A500adj->value; break;
|
|
167 case 5: eq.gain=A1000adj->value; break;
|
|
168 case 6: eq.gain=A2000adj->value; break;
|
|
169 case 7: eq.gain=A4000adj->value; break;
|
|
170 case 8: eq.gain=A8000adj->value; break;
|
|
171 case 9: eq.gain=A16000adj->value; break;
|
|
172 default: return FALSE;
|
6626
|
173 }
|
6627
|
174 eq.gain=0.0f - eq.gain;
|
|
175 eq.band=(int)user_data;
|
|
176 if ( Channel == -1 )
|
|
177 {
|
|
178 int i;
|
|
179 for ( i=0;i<6;i++ )
|
|
180 { eq.channel=i; gtkSet( gtkSetEqualizer,0,&eq ); }
|
|
181 } else { eq.channel=Channel; gtkSet( gtkSetEqualizer,0,&eq ); }
|
6626
|
182
|
6627
|
183 return FALSE;
|
6626
|
184 }
|
|
185
|
6627
|
186 static gboolean eqVScaleMotion( GtkWidget * widget,GdkEventMotion * event,gpointer user_data )
|
6626
|
187 {
|
6627
|
188
|
|
189 switch( (int)user_data )
|
6626
|
190 {
|
6627
|
191 case 1: gtkSet( gtkSetContrast,VContrastadj->value,NULL ); break;
|
|
192 case 2: gtkSet( gtkSetBrightness,VBrightnessadj->value,NULL ); break;
|
6755
|
193 case 3: gtkSet( gtkSetHue,VHueadj->value,NULL ); break;
|
6627
|
194 case 4: gtkSet( gtkSetSaturation,VSaturationadj->value,NULL ); break;
|
6626
|
195 }
|
|
196
|
6627
|
197 return FALSE;
|
6626
|
198 }
|
|
199
|
6627
|
200 static void eqButtonReleased( GtkButton * button,gpointer user_data )
|
|
201 {
|
|
202 switch( (int)user_data )
|
|
203 {
|
|
204 case 0: HideEqualizer(); break;
|
|
205 case 1:
|
6651
|
206 if ( gtk_notebook_get_current_page( GTK_NOTEBOOK( Notebook ) ) == 0 )
|
6627
|
207 {
|
6651
|
208 if ( !guiIntfStruct.Playing && !gtkEnableAudioEqualizer ) break;
|
6627
|
209 gtkSet( gtkSetEqualizer,0,NULL );
|
|
210 eqSetBands( Channel );
|
|
211 }
|
|
212 else
|
|
213 {
|
6755
|
214 if ( !guiIntfStruct.Playing || !gtkEnableVideoEqualizer ) break;
|
6627
|
215 gtkSet( gtkSetContrast,0.0f,NULL );
|
|
216 gtkSet( gtkSetBrightness,0.0f,NULL );
|
|
217 gtkSet( gtkSetHue,0.0f,NULL );
|
|
218 gtkSet( gtkSetSaturation,0.0f,NULL );
|
6755
|
219 vo_gamma_brightness=vo_gamma_contrast=vo_gamma_hue=vo_gamma_saturation=0;
|
|
220 eqSetBands( Channel );
|
6627
|
221 }
|
|
222 break;
|
6651
|
223 case 2:
|
|
224 ShowEquConfig();
|
|
225 break;
|
6627
|
226 }
|
|
227 }
|
6626
|
228
|
|
229 gboolean eqDestroy( GtkWidget * widget,GdkEvent * event,gpointer user_data )
|
|
230 { HideEqualizer(); return FALSE; }
|
|
231
|
6627
|
232 static void eqShow( GtkWidget * widget,gpointer user_data )
|
|
233 { gtkVEqualizer=(int)user_data; }
|
6626
|
234
|
6627
|
235 static void eqSelectChannelsListRow( GtkCList * clist,gint row,gint column,GdkEvent * event,gpointer user_data )
|
6626
|
236 {
|
|
237 char * tmp;
|
|
238 Channel=row - 1;
|
6627
|
239 eqSetBands( Channel );
|
|
240 if ( Channel == -1 )
|
|
241 {
|
|
242 int i,j; equalizer_t eq;
|
|
243 for ( i=1;i<6;i++ )
|
|
244 for ( j=0;j<10;j++ )
|
|
245 { eq.band=j; eq.channel=i; eq.gain=gtkEquChannels[0][j]; gtkSet( gtkSetEqualizer,0,&eq ); }
|
|
246 }
|
6626
|
247 }
|
|
248
|
6651
|
249 void eqNotebook( GtkNotebook * notebook,GtkNotebookPage * page,gint page_num,gpointer user_data )
|
|
250 {
|
|
251 if ( page_num ) gtk_widget_hide( Config );
|
|
252 else gtk_widget_show( Config );
|
|
253 }
|
|
254
|
6626
|
255 GtkWidget * create_Equalizer( void )
|
|
256 {
|
|
257 GtkWidget * frame1;
|
|
258 GtkWidget * frame2;
|
|
259 GtkWidget * frame3;
|
|
260 GtkWidget * frame4;
|
|
261 GtkWidget * vbox1;
|
|
262 GtkWidget * hbox1;
|
|
263 GtkWidget * scrolledwindow1;
|
|
264 GtkWidget * table1;
|
|
265 GtkWidget * label3;
|
|
266 GtkWidget * label4;
|
|
267 GtkWidget * label5;
|
|
268 GtkWidget * label6;
|
|
269 GtkWidget * label7;
|
|
270 GtkWidget * label8;
|
|
271 GtkWidget * label9;
|
|
272 GtkWidget * label10;
|
|
273 GtkWidget * label11;
|
|
274 GtkWidget * label12;
|
|
275 GtkWidget * label1;
|
|
276 GtkWidget * hbox2;
|
|
277 GtkWidget * vbox2;
|
|
278 GtkWidget * label13;
|
|
279 GtkWidget * label14;
|
|
280 GtkWidget * label15;
|
|
281 GtkWidget * label16;
|
|
282 GtkWidget * vbox3;
|
|
283 GtkWidget * label2;
|
|
284 GtkWidget * hbuttonbox1;
|
|
285 GtkWidget * hseparator1;
|
|
286 GtkAccelGroup * accel_group;
|
|
287
|
|
288 accel_group=gtk_accel_group_new();
|
|
289
|
|
290 Equalizer=gtk_window_new( GTK_WINDOW_DIALOG );
|
6651
|
291 gtk_widget_set_name( Equalizer,MSGTR_Equalizer );
|
|
292 gtk_object_set_data( GTK_OBJECT( Equalizer ),MSGTR_Equalizer,Equalizer );
|
6626
|
293 gtk_widget_set_usize( Equalizer,550,256 );
|
6651
|
294 gtk_window_set_title( GTK_WINDOW( Equalizer ),MSGTR_Equalizer );
|
6626
|
295 gtk_window_set_position( GTK_WINDOW( Equalizer ),GTK_WIN_POS_CENTER );
|
|
296 gtk_window_set_policy( GTK_WINDOW( Equalizer ),FALSE,FALSE,FALSE );
|
6651
|
297 gtk_window_set_wmclass( GTK_WINDOW( Equalizer ),MSGTR_Equalizer,"MPlayer" );
|
6626
|
298
|
6651
|
299 gtk_widget_realize( Equalizer );
|
|
300 gtkAddIcon( Equalizer );
|
|
301
|
6626
|
302 frame1=gtk_frame_new( NULL );
|
|
303 gtk_widget_set_name( frame1,"frame1" );
|
|
304 gtk_widget_ref( frame1 );
|
|
305 gtk_object_set_data_full( GTK_OBJECT( Equalizer ),"frame1",frame1,(GtkDestroyNotify)gtk_widget_unref );
|
|
306 gtk_widget_show( frame1 );
|
|
307 gtk_container_add( GTK_CONTAINER( Equalizer ),frame1 );
|
|
308 gtk_container_set_border_width( GTK_CONTAINER( frame1 ),1 );
|
|
309 gtk_frame_set_shadow_type( GTK_FRAME( frame1 ),GTK_SHADOW_IN );
|
|
310
|
|
311 frame2=gtk_frame_new( NULL );
|
|
312 gtk_widget_set_name( frame2,"frame2" );
|
|
313 gtk_widget_ref( frame2 );
|
|
314 gtk_object_set_data_full( GTK_OBJECT( Equalizer ),"frame2",frame2,(GtkDestroyNotify)gtk_widget_unref );
|
|
315 gtk_widget_show( frame2 );
|
|
316 gtk_container_add( GTK_CONTAINER( frame1 ),frame2 );
|
|
317 gtk_frame_set_shadow_type( GTK_FRAME( frame2 ),GTK_SHADOW_NONE );
|
|
318
|
|
319 frame3=gtk_frame_new( NULL );
|
|
320 gtk_widget_set_name( frame3,"frame3" );
|
|
321 gtk_widget_ref( frame3 );
|
|
322 gtk_object_set_data_full( GTK_OBJECT( Equalizer ),"frame3",frame3,(GtkDestroyNotify)gtk_widget_unref );
|
|
323 gtk_widget_show( frame3 );
|
|
324 gtk_container_add( GTK_CONTAINER( frame2 ),frame3 );
|
|
325 gtk_frame_set_shadow_type( GTK_FRAME( frame3 ),GTK_SHADOW_ETCHED_OUT );
|
|
326
|
|
327 frame4=gtk_frame_new( NULL );
|
|
328 gtk_widget_set_name( frame4,"frame4" );
|
|
329 gtk_widget_ref( frame4 );
|
|
330 gtk_object_set_data_full( GTK_OBJECT( Equalizer ),"frame4",frame4,(GtkDestroyNotify)gtk_widget_unref );
|
|
331 gtk_widget_show( frame4 );
|
|
332 gtk_container_add( GTK_CONTAINER( frame3 ),frame4 );
|
|
333 gtk_frame_set_shadow_type( GTK_FRAME( frame4 ),GTK_SHADOW_NONE );
|
|
334
|
|
335 vbox1=gtk_vbox_new( FALSE,0 );
|
|
336 gtk_widget_set_name( vbox1,"vbox1" );
|
|
337 gtk_widget_ref( vbox1 );
|
|
338 gtk_object_set_data_full( GTK_OBJECT( Equalizer ),"vbox1",vbox1,(GtkDestroyNotify)gtk_widget_unref );
|
|
339 gtk_widget_show( vbox1 );
|
|
340 gtk_container_add( GTK_CONTAINER( frame4 ),vbox1 );
|
|
341
|
|
342 Notebook=gtk_notebook_new();
|
|
343 gtk_widget_set_name( Notebook,"Notebook" );
|
|
344 gtk_widget_ref( Notebook );
|
|
345 gtk_object_set_data_full( GTK_OBJECT( Equalizer ),"Notebook",Notebook,(GtkDestroyNotify)gtk_widget_unref );
|
|
346 gtk_widget_show( Notebook );
|
|
347 gtk_box_pack_start( GTK_BOX( vbox1 ),Notebook,TRUE,TRUE,0 );
|
|
348 gtk_container_set_border_width( GTK_CONTAINER( Notebook ),1 );
|
|
349
|
|
350 hbox1=gtk_hbox_new( FALSE,0 );
|
|
351 gtk_widget_set_name( hbox1,"hbox1" );
|
|
352 gtk_widget_ref( hbox1 );
|
|
353 gtk_object_set_data_full( GTK_OBJECT( Equalizer ),"hbox1",hbox1,(GtkDestroyNotify)gtk_widget_unref );
|
|
354 gtk_widget_show( hbox1 );
|
|
355 gtk_container_add( GTK_CONTAINER( Notebook ),hbox1 );
|
|
356
|
|
357 scrolledwindow1=gtk_scrolled_window_new( NULL,NULL );
|
|
358 gtk_widget_set_name( scrolledwindow1,"scrolledwindow1" );
|
|
359 gtk_widget_ref( scrolledwindow1 );
|
|
360 gtk_object_set_data_full( GTK_OBJECT( Equalizer ),"scrolledwindow1",scrolledwindow1,(GtkDestroyNotify)gtk_widget_unref );
|
|
361 gtk_widget_show( scrolledwindow1 );
|
|
362 gtk_box_pack_start( GTK_BOX( hbox1 ),scrolledwindow1,FALSE,FALSE,0 );
|
|
363 gtk_widget_set_usize( scrolledwindow1,106,-2 );
|
|
364 gtk_scrolled_window_set_policy( GTK_SCROLLED_WINDOW( scrolledwindow1 ),GTK_POLICY_AUTOMATIC,GTK_POLICY_AUTOMATIC );
|
|
365
|
|
366 ChannelsList=gtk_clist_new( 1 );
|
|
367 gtk_widget_set_name( ChannelsList,"ChannelsList" );
|
|
368 gtk_widget_ref( ChannelsList );
|
|
369 gtk_object_set_data_full( GTK_OBJECT( Equalizer ),"ChannelsList",ChannelsList,(GtkDestroyNotify)gtk_widget_unref );
|
|
370 gtk_widget_show( ChannelsList );
|
|
371 gtk_container_add( GTK_CONTAINER( scrolledwindow1 ),ChannelsList );
|
|
372 gtk_clist_set_column_width( GTK_CLIST( ChannelsList ),0,80 );
|
|
373 gtk_clist_column_titles_hide( GTK_CLIST( ChannelsList ) );
|
|
374
|
|
375 table1=gtk_table_new( 2,10,FALSE );
|
|
376 gtk_widget_set_name( table1,"table1" );
|
|
377 gtk_widget_ref( table1 );
|
|
378 gtk_object_set_data_full( GTK_OBJECT( Equalizer ),"table1",table1,(GtkDestroyNotify)gtk_widget_unref );
|
|
379 gtk_widget_show( table1 );
|
|
380 gtk_box_pack_start( GTK_BOX( hbox1 ),table1,FALSE,FALSE,0 );
|
|
381 gtk_table_set_row_spacings( GTK_TABLE( table1 ),4 );
|
|
382 gtk_table_set_col_spacings( GTK_TABLE( table1 ),9 );
|
|
383
|
6755
|
384 A3125adj=GTK_ADJUSTMENT( gtk_adjustment_new( 0,-3,3,0.5,0,0 ) );
|
6626
|
385 A3125=gtk_vscale_new( A3125adj );
|
|
386 gtk_widget_set_name( A3125,"A3125" );
|
|
387 gtk_widget_ref( A3125 );
|
|
388 gtk_object_set_data_full( GTK_OBJECT( Equalizer ),"A3125",A3125,(GtkDestroyNotify)gtk_widget_unref );
|
|
389 gtk_widget_show( A3125 );
|
|
390 gtk_table_attach( GTK_TABLE( table1 ),A3125,0,1,0,1,( GtkAttachOptions )( GTK_FILL ),( GtkAttachOptions )( GTK_EXPAND | GTK_FILL ),0,0 );
|
|
391 gtk_scale_set_draw_value( GTK_SCALE( A3125 ),FALSE );
|
|
392
|
6755
|
393 A6250adj=GTK_ADJUSTMENT( gtk_adjustment_new( 0,-3,3,0.5,0,0 ) );
|
6626
|
394 A6250=gtk_vscale_new( A6250adj );
|
|
395 gtk_widget_set_name( A6250,"A6250" );
|
|
396 gtk_widget_ref( A6250 );
|
|
397 gtk_object_set_data_full( GTK_OBJECT( Equalizer ),"A6250",A6250,(GtkDestroyNotify)gtk_widget_unref );
|
|
398 gtk_widget_show( A6250 );
|
|
399 gtk_table_attach( GTK_TABLE( table1 ),A6250,1,2,0,1,( GtkAttachOptions )( GTK_FILL ),( GtkAttachOptions )( GTK_EXPAND | GTK_FILL ),0,0 );
|
|
400 gtk_scale_set_draw_value( GTK_SCALE( A6250 ),FALSE );
|
|
401
|
6755
|
402 A125adj=GTK_ADJUSTMENT( gtk_adjustment_new( 0,-3,3,0.5,0,0 ) );
|
6626
|
403 A125=gtk_vscale_new( A125adj );
|
|
404 gtk_widget_set_name( A125,"A125" );
|
|
405 gtk_widget_ref( A125 );
|
|
406 gtk_object_set_data_full( GTK_OBJECT( Equalizer ),"A125",A125,(GtkDestroyNotify)gtk_widget_unref );
|
|
407 gtk_widget_show( A125 );
|
|
408 gtk_table_attach( GTK_TABLE( table1 ),A125,2,3,0,1,( GtkAttachOptions )( GTK_FILL ),( GtkAttachOptions )( GTK_EXPAND | GTK_FILL ),0,0 );
|
|
409 gtk_scale_set_draw_value( GTK_SCALE( A125 ),FALSE );
|
|
410
|
6755
|
411 A250adj=GTK_ADJUSTMENT( gtk_adjustment_new( 0,-3,3,0.5,0,0 ) );
|
6626
|
412 A250=gtk_vscale_new( A250adj );
|
|
413 gtk_widget_set_name( A250,"A250" );
|
|
414 gtk_widget_ref( A250 );
|
|
415 gtk_object_set_data_full( GTK_OBJECT( Equalizer ),"A250",A250,(GtkDestroyNotify)gtk_widget_unref );
|
|
416 gtk_widget_show( A250 );
|
|
417 gtk_table_attach( GTK_TABLE( table1 ),A250,3,4,0,1,( GtkAttachOptions )( GTK_FILL ),( GtkAttachOptions )( GTK_EXPAND | GTK_FILL ),0,0 );
|
|
418 gtk_scale_set_draw_value( GTK_SCALE( A250 ),FALSE );
|
|
419
|
6755
|
420 A500adj=GTK_ADJUSTMENT( gtk_adjustment_new( 0,-3,3,0.5,0,0 ) );
|
6626
|
421 A500=gtk_vscale_new( A500adj );
|
|
422 gtk_widget_set_name( A500,"A500" );
|
|
423 gtk_widget_ref( A500 );
|
|
424 gtk_object_set_data_full( GTK_OBJECT( Equalizer ),"A500",A500,(GtkDestroyNotify)gtk_widget_unref );
|
|
425 gtk_widget_show( A500 );
|
|
426 gtk_table_attach( GTK_TABLE( table1 ),A500,4,5,0,1,( GtkAttachOptions )( GTK_FILL ),( GtkAttachOptions )( GTK_EXPAND | GTK_FILL ),0,0 );
|
|
427 gtk_scale_set_draw_value( GTK_SCALE( A500 ),FALSE );
|
|
428
|
6755
|
429 A1000adj=GTK_ADJUSTMENT( gtk_adjustment_new( 0,-3,3,0.5,0,0 ) );
|
6626
|
430 A1000=gtk_vscale_new( A1000adj );
|
|
431 gtk_widget_set_name( A1000,"A1000" );
|
|
432 gtk_widget_ref( A1000 );
|
|
433 gtk_object_set_data_full( GTK_OBJECT( Equalizer ),"A1000",A1000,(GtkDestroyNotify)gtk_widget_unref );
|
|
434 gtk_widget_show( A1000 );
|
|
435 gtk_table_attach( GTK_TABLE( table1 ),A1000,5,6,0,1,( GtkAttachOptions )( GTK_FILL ),( GtkAttachOptions )( GTK_EXPAND | GTK_FILL ),0,0 );
|
|
436 gtk_scale_set_draw_value( GTK_SCALE( A1000 ),FALSE );
|
|
437
|
6755
|
438 A2000adj=GTK_ADJUSTMENT( gtk_adjustment_new( 0,-3,3,0.5,0,0 ) );
|
6626
|
439 A2000=gtk_vscale_new( A2000adj );
|
|
440 gtk_widget_set_name( A2000,"A2000" );
|
|
441 gtk_widget_ref( A2000 );
|
|
442 gtk_object_set_data_full( GTK_OBJECT( Equalizer ),"A2000",A2000,(GtkDestroyNotify)gtk_widget_unref );
|
|
443 gtk_widget_show( A2000 );
|
|
444 gtk_table_attach( GTK_TABLE( table1 ),A2000,6,7,0,1,( GtkAttachOptions )( GTK_FILL ),( GtkAttachOptions )( GTK_EXPAND | GTK_FILL ),0,0 );
|
|
445 gtk_scale_set_draw_value( GTK_SCALE( A2000 ),FALSE );
|
|
446
|
6755
|
447 A4000adj=GTK_ADJUSTMENT( gtk_adjustment_new( 0,-3,3,0.5,0,0 ) );
|
6626
|
448 A4000=gtk_vscale_new( A4000adj );
|
|
449 gtk_widget_set_name( A4000,"A4000" );
|
|
450 gtk_widget_ref( A4000 );
|
|
451 gtk_object_set_data_full( GTK_OBJECT( Equalizer ),"A4000",A4000,(GtkDestroyNotify)gtk_widget_unref );
|
|
452 gtk_widget_show( A4000 );
|
|
453 gtk_table_attach( GTK_TABLE( table1 ),A4000,7,8,0,1,( GtkAttachOptions )( GTK_FILL ),( GtkAttachOptions )( GTK_EXPAND | GTK_FILL ),0,0 );
|
|
454 gtk_scale_set_draw_value( GTK_SCALE( A4000 ),FALSE );
|
|
455
|
6755
|
456 A8000adj=GTK_ADJUSTMENT( gtk_adjustment_new( 0,-3,3,0.5,0,0 ) );
|
6626
|
457 A8000=gtk_vscale_new( A8000adj );
|
|
458 gtk_widget_set_name( A8000,"A8000" );
|
|
459 gtk_widget_ref( A8000 );
|
|
460 gtk_object_set_data_full( GTK_OBJECT( Equalizer ),"A8000",A8000,(GtkDestroyNotify)gtk_widget_unref );
|
|
461 gtk_widget_show( A8000 );
|
|
462 gtk_table_attach( GTK_TABLE( table1 ),A8000,8,9,0,1,( GtkAttachOptions )( GTK_FILL ),( GtkAttachOptions )( GTK_EXPAND | GTK_FILL ),0,0 );
|
|
463 gtk_scale_set_draw_value( GTK_SCALE( A8000 ),FALSE );
|
|
464
|
6755
|
465 A16000adj=GTK_ADJUSTMENT( gtk_adjustment_new( 0,-3,3,0.5,0,0 ) );
|
6626
|
466 A16000=gtk_vscale_new( A16000adj );
|
|
467 gtk_widget_set_name( A16000,"A16000" );
|
|
468 gtk_widget_ref( A16000 );
|
|
469 gtk_object_set_data_full( GTK_OBJECT( Equalizer ),"A16000",A16000,(GtkDestroyNotify)gtk_widget_unref );
|
|
470 gtk_widget_show( A16000 );
|
|
471 gtk_table_attach( GTK_TABLE( table1 ),A16000,9,10,0,1,( GtkAttachOptions )( GTK_FILL ),( GtkAttachOptions )( GTK_EXPAND | GTK_FILL ),0,0 );
|
|
472 gtk_scale_set_draw_value( GTK_SCALE( A16000 ),FALSE );
|
|
473
|
|
474 label3=gtk_label_new( "31.25" );
|
|
475 gtk_widget_set_name( label3,"label3" );
|
|
476 gtk_widget_ref( label3 );
|
|
477 gtk_object_set_data_full( GTK_OBJECT( Equalizer ),"label3",label3,(GtkDestroyNotify)gtk_widget_unref );
|
|
478 gtk_widget_show( label3 );
|
|
479 gtk_table_attach( GTK_TABLE( table1 ),label3,0,1,1,2,( GtkAttachOptions )( GTK_FILL ),( GtkAttachOptions )( 0 ),0,0 );
|
|
480 gtk_misc_set_alignment( GTK_MISC( label3 ),0,0.5 );
|
|
481 gtk_misc_set_padding( GTK_MISC( label3 ),2,0 );
|
|
482
|
|
483 label4=gtk_label_new( "62.50" );
|
|
484 gtk_widget_set_name( label4,"label4" );
|
|
485 gtk_widget_ref( label4 );
|
|
486 gtk_object_set_data_full( GTK_OBJECT( Equalizer ),"label4",label4,(GtkDestroyNotify)gtk_widget_unref );
|
|
487 gtk_widget_show( label4 );
|
|
488 gtk_table_attach( GTK_TABLE( table1 ),label4,1,2,1,2,( GtkAttachOptions )( GTK_FILL ),( GtkAttachOptions )( 0 ),0,0 );
|
|
489 gtk_misc_set_alignment( GTK_MISC( label4 ),0,0.5 );
|
|
490 gtk_misc_set_padding( GTK_MISC( label4 ),1,0 );
|
|
491
|
|
492 label5=gtk_label_new( "125" );
|
|
493 gtk_widget_set_name( label5,"label5" );
|
|
494 gtk_widget_ref( label5 );
|
|
495 gtk_object_set_data_full( GTK_OBJECT( Equalizer ),"label5",label5,(GtkDestroyNotify)gtk_widget_unref );
|
|
496 gtk_widget_show( label5 );
|
|
497 gtk_table_attach( GTK_TABLE( table1 ),label5,2,3,1,2,( GtkAttachOptions )( GTK_FILL ),( GtkAttachOptions )( 0 ),0,0 );
|
|
498 gtk_misc_set_alignment( GTK_MISC( label5 ),0,0.5 );
|
|
499 gtk_misc_set_padding( GTK_MISC( label5 ),5,0 );
|
|
500
|
|
501 label6=gtk_label_new( "250" );
|
|
502 gtk_widget_set_name( label6,"label6" );
|
|
503 gtk_widget_ref( label6 );
|
|
504 gtk_object_set_data_full( GTK_OBJECT( Equalizer ),"label6",label6,(GtkDestroyNotify)gtk_widget_unref );
|
|
505 gtk_widget_show( label6 );
|
|
506 gtk_table_attach( GTK_TABLE( table1 ),label6,3,4,1,2,( GtkAttachOptions )( GTK_FILL ),( GtkAttachOptions )( 0 ),0,0 );
|
|
507 gtk_misc_set_alignment( GTK_MISC( label6 ),0,0.5 );
|
|
508 gtk_misc_set_padding( GTK_MISC( label6 ),5,0 );
|
|
509
|
|
510 label7=gtk_label_new( "500" );
|
|
511 gtk_widget_set_name( label7,"label7" );
|
|
512 gtk_widget_ref( label7 );
|
|
513 gtk_object_set_data_full( GTK_OBJECT( Equalizer ),"label7",label7,(GtkDestroyNotify)gtk_widget_unref );
|
|
514 gtk_widget_show( label7 );
|
|
515 gtk_table_attach( GTK_TABLE( table1 ),label7,4,5,1,2,( GtkAttachOptions )( GTK_FILL ),( GtkAttachOptions )( 0 ),0,0 );
|
|
516 gtk_misc_set_alignment( GTK_MISC( label7 ),0,0.5 );
|
|
517 gtk_misc_set_padding( GTK_MISC( label7 ),7,0 );
|
|
518
|
|
519 label8=gtk_label_new( "1000" );
|
|
520 gtk_widget_set_name( label8,"label8" );
|
|
521 gtk_widget_ref( label8 );
|
|
522 gtk_object_set_data_full( GTK_OBJECT( Equalizer ),"label8",label8,(GtkDestroyNotify)gtk_widget_unref );
|
|
523 gtk_widget_show( label8 );
|
|
524 gtk_table_attach( GTK_TABLE( table1 ),label8,5,6,1,2,( GtkAttachOptions )( GTK_FILL ),( GtkAttachOptions )( 0 ),0,0 );
|
|
525 gtk_misc_set_alignment( GTK_MISC( label8 ),0,0.5 );
|
|
526 gtk_misc_set_padding( GTK_MISC( label8 ),5,0 );
|
|
527
|
|
528 label9=gtk_label_new( "2000" );
|
|
529 gtk_widget_set_name( label9,"label9" );
|
|
530 gtk_widget_ref( label9 );
|
|
531 gtk_object_set_data_full( GTK_OBJECT( Equalizer ),"label9",label9,(GtkDestroyNotify)gtk_widget_unref );
|
|
532 gtk_widget_show( label9 );
|
|
533 gtk_table_attach( GTK_TABLE( table1 ),label9,6,7,1,2,( GtkAttachOptions )( GTK_FILL ),( GtkAttachOptions )( 0 ),0,0 );
|
|
534 gtk_misc_set_alignment( GTK_MISC( label9 ),0,0.5 );
|
|
535 gtk_misc_set_padding( GTK_MISC( label9 ),2,0 );
|
|
536
|
|
537 label10=gtk_label_new( "4000" );
|
|
538 gtk_widget_set_name( label10,"label10" );
|
|
539 gtk_widget_ref( label10 );
|
|
540 gtk_object_set_data_full( GTK_OBJECT( Equalizer ),"label10",label10,(GtkDestroyNotify)gtk_widget_unref );
|
|
541 gtk_widget_show( label10 );
|
|
542 gtk_table_attach( GTK_TABLE( table1 ),label10,7,8,1,2,( GtkAttachOptions )( GTK_FILL ),( GtkAttachOptions )( 0 ),0,0 );
|
|
543 gtk_misc_set_alignment( GTK_MISC( label10 ),0,0.5 );
|
|
544 gtk_misc_set_padding( GTK_MISC( label10 ),3,0 );
|
|
545
|
|
546 label11=gtk_label_new( "8000" );
|
|
547 gtk_widget_set_name( label11,"label11" );
|
|
548 gtk_widget_ref( label11 );
|
|
549 gtk_object_set_data_full( GTK_OBJECT( Equalizer ),"label11",label11,(GtkDestroyNotify)gtk_widget_unref );
|
|
550 gtk_widget_show( label11 );
|
|
551 gtk_table_attach( GTK_TABLE( table1 ),label11,8,9,1,2,( GtkAttachOptions )( GTK_FILL ),( GtkAttachOptions )( 0 ),0,0 );
|
|
552 gtk_misc_set_alignment( GTK_MISC( label11 ),0,0.5 );
|
|
553 gtk_misc_set_padding( GTK_MISC( label11 ),1,0 );
|
|
554
|
|
555 label12=gtk_label_new( "16000" );
|
|
556 gtk_widget_set_name( label12,"label12" );
|
|
557 gtk_widget_ref( label12 );
|
|
558 gtk_object_set_data_full( GTK_OBJECT( Equalizer ),"label12",label12,(GtkDestroyNotify)gtk_widget_unref );
|
|
559 gtk_widget_show( label12 );
|
|
560 gtk_table_attach( GTK_TABLE( table1 ),label12,9,10,1,2,( GtkAttachOptions )( GTK_FILL ),( GtkAttachOptions )( 0 ),0,0 );
|
|
561 gtk_misc_set_alignment( GTK_MISC( label12 ),0,0.5 );
|
|
562
|
6651
|
563 label1=gtk_label_new( MSGTR_EQU_Audio );
|
6626
|
564 gtk_widget_set_name( label1,"label1" );
|
|
565 gtk_widget_ref( label1 );
|
|
566 gtk_object_set_data_full( GTK_OBJECT( Equalizer ),"label1",label1,(GtkDestroyNotify)gtk_widget_unref );
|
|
567 gtk_widget_show( label1 );
|
|
568 gtk_notebook_set_tab_label( GTK_NOTEBOOK( Notebook ),gtk_notebook_get_nth_page( GTK_NOTEBOOK( Notebook ),0 ),label1 );
|
|
569
|
|
570 hbox2=gtk_hbox_new( FALSE,0 );
|
|
571 gtk_widget_set_name( hbox2,"hbox2" );
|
|
572 gtk_widget_ref( hbox2 );
|
|
573 gtk_object_set_data_full( GTK_OBJECT( Equalizer ),"hbox2",hbox2,(GtkDestroyNotify)gtk_widget_unref );
|
|
574 gtk_widget_show( hbox2 );
|
|
575 gtk_container_add( GTK_CONTAINER( Notebook ),hbox2 );
|
|
576
|
|
577 vbox2=gtk_vbox_new( TRUE,0 );
|
|
578 gtk_widget_set_name( vbox2,"vbox2" );
|
|
579 gtk_widget_ref( vbox2 );
|
|
580 gtk_object_set_data_full( GTK_OBJECT( Equalizer ),"vbox2",vbox2,(GtkDestroyNotify)gtk_widget_unref );
|
|
581 gtk_widget_show( vbox2 );
|
|
582 gtk_box_pack_start( GTK_BOX( hbox2 ),vbox2,FALSE,FALSE,0 );
|
|
583
|
6651
|
584 label13=gtk_label_new( MSGTR_EQU_Contrast );
|
6626
|
585 gtk_widget_set_name( label13,"label13" );
|
|
586 gtk_widget_ref( label13 );
|
|
587 gtk_object_set_data_full( GTK_OBJECT( Equalizer ),"label13",label13,(GtkDestroyNotify)gtk_widget_unref );
|
|
588 gtk_widget_show( label13 );
|
|
589 gtk_box_pack_start( GTK_BOX( vbox2 ),label13,FALSE,FALSE,0 );
|
|
590 gtk_label_set_justify( GTK_LABEL( label13 ),GTK_JUSTIFY_LEFT );
|
|
591 gtk_misc_set_alignment( GTK_MISC( label13 ),0.02,0.5 );
|
|
592
|
6651
|
593 label14=gtk_label_new( MSGTR_EQU_Brightness );
|
6626
|
594 gtk_widget_set_name( label14,"label14" );
|
|
595 gtk_widget_ref( label14 );
|
|
596 gtk_object_set_data_full( GTK_OBJECT( Equalizer ),"label14",label14,(GtkDestroyNotify)gtk_widget_unref );
|
|
597 gtk_widget_show( label14 );
|
|
598 gtk_box_pack_start( GTK_BOX( vbox2 ),label14,FALSE,FALSE,0 );
|
|
599 gtk_label_set_justify( GTK_LABEL( label14 ),GTK_JUSTIFY_LEFT );
|
|
600 gtk_misc_set_alignment( GTK_MISC( label14 ),0.02,0.5 );
|
|
601
|
6651
|
602 label15=gtk_label_new( MSGTR_EQU_Hue );
|
6626
|
603 gtk_widget_set_name( label15,"label15" );
|
|
604 gtk_widget_ref( label15 );
|
|
605 gtk_object_set_data_full( GTK_OBJECT( Equalizer ),"label15",label15,(GtkDestroyNotify)gtk_widget_unref );
|
|
606 gtk_widget_show( label15 );
|
|
607 gtk_box_pack_start( GTK_BOX( vbox2 ),label15,FALSE,FALSE,0 );
|
|
608 gtk_label_set_justify( GTK_LABEL( label15 ),GTK_JUSTIFY_LEFT );
|
|
609 gtk_misc_set_alignment( GTK_MISC( label15 ),0.02,0.5 );
|
|
610
|
6651
|
611 label16=gtk_label_new( MSGTR_EQU_Saturation );
|
6626
|
612 gtk_widget_set_name( label16,"label16" );
|
|
613 gtk_widget_ref( label16 );
|
|
614 gtk_object_set_data_full( GTK_OBJECT( Equalizer ),"label16",label16,(GtkDestroyNotify)gtk_widget_unref );
|
|
615 gtk_widget_show( label16 );
|
|
616 gtk_box_pack_start( GTK_BOX( vbox2 ),label16,FALSE,FALSE,0 );
|
|
617 gtk_label_set_justify( GTK_LABEL( label16 ),GTK_JUSTIFY_LEFT );
|
|
618 gtk_misc_set_alignment( GTK_MISC( label16 ),0.02,0.5 );
|
|
619
|
|
620 vbox3=gtk_vbox_new( TRUE,0 );
|
|
621 gtk_widget_set_name( vbox3,"vbox3" );
|
|
622 gtk_widget_ref( vbox3 );
|
|
623 gtk_object_set_data_full( GTK_OBJECT( Equalizer ),"vbox3",vbox3,(GtkDestroyNotify)gtk_widget_unref );
|
|
624 gtk_widget_show( vbox3 );
|
|
625 gtk_box_pack_start( GTK_BOX( hbox2 ),vbox3,TRUE,TRUE,0 );
|
|
626
|
6755
|
627 VContrastadj=GTK_ADJUSTMENT( gtk_adjustment_new( 0,-100,100,1,0,0 ) );
|
6626
|
628 VContrast=gtk_hscale_new( VContrastadj );
|
|
629 gtk_widget_set_name( VContrast,"VContrast" );
|
|
630 gtk_widget_ref( VContrast );
|
|
631 gtk_object_set_data_full( GTK_OBJECT( Equalizer ),"VContrast",VContrast,(GtkDestroyNotify)gtk_widget_unref );
|
|
632 gtk_widget_show( VContrast );
|
|
633 gtk_box_pack_start( GTK_BOX( vbox3 ),VContrast,TRUE,TRUE,0 );
|
|
634 gtk_scale_set_value_pos( GTK_SCALE( VContrast ),GTK_POS_RIGHT );
|
|
635
|
6755
|
636 VBrightnessadj=GTK_ADJUSTMENT( gtk_adjustment_new( 0,-100,100,1,0,0 ) );
|
6626
|
637 VBrightness=gtk_hscale_new( VBrightnessadj );
|
|
638 gtk_widget_set_name( VBrightness,"VBrightness" );
|
|
639 gtk_widget_ref( VBrightness );
|
|
640 gtk_object_set_data_full( GTK_OBJECT( Equalizer ),"VBrightness",VBrightness,(GtkDestroyNotify)gtk_widget_unref );
|
|
641 gtk_widget_show( VBrightness );
|
|
642 gtk_box_pack_start( GTK_BOX( vbox3 ),VBrightness,TRUE,TRUE,0 );
|
|
643 gtk_scale_set_value_pos( GTK_SCALE( VBrightness ),GTK_POS_RIGHT );
|
|
644
|
6755
|
645 VHueadj=GTK_ADJUSTMENT( gtk_adjustment_new( 0,-100,100,1,0,0 ) );
|
6626
|
646 VHue=gtk_hscale_new( VHueadj );
|
|
647 gtk_widget_set_name( VHue,"VHue" );
|
|
648 gtk_widget_ref( VHue );
|
|
649 gtk_object_set_data_full( GTK_OBJECT( Equalizer ),"VHue",VHue,(GtkDestroyNotify)gtk_widget_unref );
|
|
650 gtk_widget_show( VHue );
|
|
651 gtk_box_pack_start( GTK_BOX( vbox3 ),VHue,TRUE,TRUE,0 );
|
|
652 gtk_scale_set_value_pos( GTK_SCALE( VHue ),GTK_POS_RIGHT );
|
|
653
|
6755
|
654 VSaturationadj=GTK_ADJUSTMENT( gtk_adjustment_new( 0,-100,100,1,0,0 ) );
|
6626
|
655 VSaturation=gtk_hscale_new( VSaturationadj );
|
|
656 gtk_widget_set_name( VSaturation,"VSaturation" );
|
|
657 gtk_widget_ref( VSaturation );
|
|
658 gtk_object_set_data_full( GTK_OBJECT( Equalizer ),"VSaturation",VSaturation,(GtkDestroyNotify)gtk_widget_unref );
|
|
659 gtk_widget_show( VSaturation );
|
|
660 gtk_box_pack_start( GTK_BOX( vbox3 ),VSaturation,TRUE,TRUE,0 );
|
|
661 gtk_scale_set_value_pos( GTK_SCALE( VSaturation ),GTK_POS_RIGHT );
|
|
662
|
6651
|
663 label2=gtk_label_new( MSGTR_EQU_Video );
|
6626
|
664 gtk_widget_set_name( label2,"label2" );
|
|
665 gtk_widget_ref( label2 );
|
|
666 gtk_object_set_data_full( GTK_OBJECT( Equalizer ),"label2",label2,(GtkDestroyNotify)gtk_widget_unref );
|
|
667 gtk_widget_show( label2 );
|
|
668 gtk_notebook_set_tab_label( GTK_NOTEBOOK( Notebook ),gtk_notebook_get_nth_page( GTK_NOTEBOOK( Notebook ),1 ),label2 );
|
|
669
|
|
670 hbuttonbox1=gtk_hbutton_box_new();
|
|
671 gtk_widget_set_name( hbuttonbox1,"hbuttonbox1" );
|
|
672 gtk_widget_ref( hbuttonbox1 );
|
|
673 gtk_object_set_data_full( GTK_OBJECT( Equalizer ),"hbuttonbox1",hbuttonbox1,(GtkDestroyNotify)gtk_widget_unref );
|
|
674 gtk_widget_show( hbuttonbox1 );
|
|
675 gtk_box_pack_end( GTK_BOX( vbox1 ),hbuttonbox1,FALSE,TRUE,0 );
|
|
676 gtk_button_box_set_layout( GTK_BUTTON_BOX( hbuttonbox1 ),GTK_BUTTONBOX_END );
|
6651
|
677 gtk_button_box_set_spacing( GTK_BUTTON_BOX( hbuttonbox1 ),10 );
|
|
678 gtk_button_box_set_child_size( GTK_BUTTON_BOX( hbuttonbox1 ),85,20 );
|
6627
|
679
|
6651
|
680 Config=gtk_button_new_with_label( MSGTR_Config );
|
|
681 gtk_widget_set_name( Config,"Config" );
|
|
682 gtk_widget_ref( Config );
|
|
683 gtk_object_set_data_full( GTK_OBJECT( Equalizer ),"Config",Config,(GtkDestroyNotify)gtk_widget_unref );
|
|
684 gtk_container_add( GTK_CONTAINER( hbuttonbox1 ),Config );
|
|
685
|
|
686 Clear=gtk_button_new_with_label( MSGTR_Clear );
|
6627
|
687 gtk_widget_set_name( Clear,"Clear" );
|
|
688 gtk_widget_ref( Clear );
|
|
689 gtk_object_set_data_full( GTK_OBJECT( Equalizer ),"Clear",Clear,(GtkDestroyNotify)gtk_widget_unref );
|
|
690 gtk_widget_show( Clear );
|
|
691 gtk_container_add( GTK_CONTAINER( hbuttonbox1 ),Clear );
|
6626
|
692
|
6651
|
693 Ok=gtk_button_new_with_label( MSGTR_Ok );
|
6626
|
694 gtk_widget_set_name( Ok,"Ok" );
|
|
695 gtk_widget_ref( Ok );
|
|
696 gtk_object_set_data_full( GTK_OBJECT( Equalizer ),"Ok",Ok,(GtkDestroyNotify)gtk_widget_unref );
|
|
697 gtk_widget_show( Ok );
|
|
698 gtk_container_add( GTK_CONTAINER( hbuttonbox1 ),Ok );
|
|
699 gtk_widget_add_accelerator( Ok,"released",accel_group,GDK_Escape,0,GTK_ACCEL_VISIBLE );
|
|
700 gtk_widget_add_accelerator( Ok,"released",accel_group,GDK_Return,0,GTK_ACCEL_VISIBLE );
|
|
701
|
|
702 hseparator1=gtk_hseparator_new();
|
|
703 gtk_widget_set_name( hseparator1,"hseparator1" );
|
|
704 gtk_widget_ref( hseparator1 );
|
|
705 gtk_object_set_data_full( GTK_OBJECT( Equalizer ),"hseparator1",hseparator1,(GtkDestroyNotify)gtk_widget_unref );
|
|
706 gtk_widget_show( hseparator1 );
|
|
707 gtk_box_pack_start( GTK_BOX( vbox1 ),hseparator1,FALSE,FALSE,0 );
|
|
708 gtk_widget_set_usize( hseparator1,-2,5 );
|
|
709
|
|
710 gtk_signal_connect( GTK_OBJECT( Equalizer ),"destroy",GTK_SIGNAL_FUNC( eqDestroy ),NULL );
|
6627
|
711 gtk_signal_connect( GTK_OBJECT( Equalizer ),"show",GTK_SIGNAL_FUNC( eqShow ),(void *)1 );
|
|
712 gtk_signal_connect( GTK_OBJECT( Equalizer ),"hide",GTK_SIGNAL_FUNC( eqShow ),(void *)0 );
|
6626
|
713 gtk_signal_connect( GTK_OBJECT( ChannelsList ),"select_row",GTK_SIGNAL_FUNC( eqSelectChannelsListRow ),NULL );
|
|
714
|
|
715 gtk_signal_connect( GTK_OBJECT( A3125 ),"motion_notify_event",GTK_SIGNAL_FUNC( eqHScaleMotion ),(void*)0 );
|
|
716 gtk_signal_connect( GTK_OBJECT( A6250 ),"motion_notify_event",GTK_SIGNAL_FUNC( eqHScaleMotion ),(void*)1 );
|
|
717 gtk_signal_connect( GTK_OBJECT( A125 ),"motion_notify_event",GTK_SIGNAL_FUNC( eqHScaleMotion ),(void*)2 );
|
|
718 gtk_signal_connect( GTK_OBJECT( A250 ),"motion_notify_event",GTK_SIGNAL_FUNC( eqHScaleMotion ),(void*)3 );
|
|
719 gtk_signal_connect( GTK_OBJECT( A500 ),"motion_notify_event",GTK_SIGNAL_FUNC( eqHScaleMotion ),(void*)4 );
|
|
720 gtk_signal_connect( GTK_OBJECT( A1000 ),"motion_notify_event",GTK_SIGNAL_FUNC( eqHScaleMotion ),(void*)5 );
|
|
721 gtk_signal_connect( GTK_OBJECT( A2000 ),"motion_notify_event",GTK_SIGNAL_FUNC( eqHScaleMotion ),(void*)6 );
|
|
722 gtk_signal_connect( GTK_OBJECT( A4000 ),"motion_notify_event",GTK_SIGNAL_FUNC( eqHScaleMotion ),(void*)7 );
|
|
723 gtk_signal_connect( GTK_OBJECT( A8000 ),"motion_notify_event",GTK_SIGNAL_FUNC( eqHScaleMotion ),(void*)8 );
|
|
724 gtk_signal_connect( GTK_OBJECT( A16000 ),"motion_notify_event",GTK_SIGNAL_FUNC( eqHScaleMotion ),(void*)9 );
|
|
725
|
|
726 gtk_signal_connect( GTK_OBJECT( VContrast ),"motion_notify_event",GTK_SIGNAL_FUNC( eqVScaleMotion ),(void*)1 );
|
|
727 gtk_signal_connect( GTK_OBJECT( VBrightness ),"motion_notify_event",GTK_SIGNAL_FUNC( eqVScaleMotion ),(void*)2 );
|
|
728 gtk_signal_connect( GTK_OBJECT( VHue ),"motion_notify_event",GTK_SIGNAL_FUNC( eqVScaleMotion ),(void*)3 );
|
|
729 gtk_signal_connect( GTK_OBJECT( VSaturation ),"motion_notify_event",GTK_SIGNAL_FUNC( eqVScaleMotion ),(void *)4 );
|
|
730
|
6627
|
731 gtk_signal_connect( GTK_OBJECT( Ok ),"released",GTK_SIGNAL_FUNC( eqButtonReleased ),(void *)0 );
|
|
732 gtk_signal_connect( GTK_OBJECT( Clear ),"released",GTK_SIGNAL_FUNC( eqButtonReleased ),(void *)1 );
|
6651
|
733 gtk_signal_connect( GTK_OBJECT( Config ),"released",GTK_SIGNAL_FUNC( eqButtonReleased ),(void *)2 );
|
|
734
|
|
735 gtk_signal_connect( GTK_OBJECT( Notebook ),"switch_page",GTK_SIGNAL_FUNC( eqNotebook ),NULL );
|
6626
|
736
|
|
737 gtk_window_add_accel_group( GTK_WINDOW( Equalizer ),accel_group );
|
|
738
|
|
739 return Equalizer;
|
|
740 }
|
|
741
|
6651
|
742 // --- equalizer config dialog box
|
|
743
|
|
744 static GtkWidget * EquConfig;
|
|
745 static GtkWidget * CBChannel1;
|
|
746 static GtkWidget * CEChannel1;
|
|
747 static GtkWidget * CBChannel2;
|
|
748 static GtkWidget * CEChannel2;
|
|
749 static GtkWidget * CBChannel3;
|
|
750 static GtkWidget * CEChannel3;
|
|
751 static GtkWidget * CBChannel4;
|
|
752 static GtkWidget * CEChannel4;
|
|
753 static GtkWidget * CBChannel5;
|
|
754 static GtkWidget * CEChannel5;
|
|
755 static GtkWidget * CBChannel6;
|
|
756 static GtkWidget * CEChannel6;
|
|
757 static GtkWidget * ecOk;
|
|
758 static GtkWidget * ecCancel;
|
|
759
|
|
760 GtkWidget * create_EquConfig( void );
|
|
761
|
|
762 void ShowEquConfig( void )
|
|
763 {
|
|
764 GList * Items = NULL;
|
|
765
|
|
766 if ( gtkVEquConfig ) gtkActive( EquConfig );
|
|
767 else EquConfig=create_EquConfig();
|
|
768
|
|
769 Items=g_list_append( Items,(gpointer)MSGTR_EQU_Front_Right );
|
|
770 Items=g_list_append( Items,(gpointer)MSGTR_EQU_Front_Left );
|
|
771 Items=g_list_append( Items,(gpointer)MSGTR_EQU_Back_Right );
|
|
772 Items=g_list_append( Items,(gpointer)MSGTR_EQU_Back_Left );
|
|
773 Items=g_list_append( Items,(gpointer)MSGTR_EQU_Center );
|
|
774 Items=g_list_append( Items,(gpointer)MSGTR_EQU_Bass );
|
|
775
|
|
776 gtk_combo_set_popdown_strings( GTK_COMBO( CBChannel1 ),Items );
|
|
777 gtk_combo_set_popdown_strings( GTK_COMBO( CBChannel2 ),Items );
|
|
778 gtk_combo_set_popdown_strings( GTK_COMBO( CBChannel3 ),Items );
|
|
779 gtk_combo_set_popdown_strings( GTK_COMBO( CBChannel4 ),Items );
|
|
780 gtk_combo_set_popdown_strings( GTK_COMBO( CBChannel5 ),Items );
|
|
781 gtk_combo_set_popdown_strings( GTK_COMBO( CBChannel6 ),Items );
|
|
782
|
|
783 g_list_free( Items );
|
|
784
|
|
785 gtk_entry_set_text( GTK_ENTRY( CEChannel1 ),gtkEquChannel1 ); gtk_entry_set_editable( GTK_ENTRY( CEChannel1 ),FALSE );
|
|
786 gtk_entry_set_text( GTK_ENTRY( CEChannel2 ),gtkEquChannel2 ); gtk_entry_set_editable( GTK_ENTRY( CEChannel2 ),FALSE );
|
|
787 gtk_entry_set_text( GTK_ENTRY( CEChannel3 ),gtkEquChannel3 ); gtk_entry_set_editable( GTK_ENTRY( CEChannel3 ),FALSE );
|
|
788 gtk_entry_set_text( GTK_ENTRY( CEChannel4 ),gtkEquChannel4 ); gtk_entry_set_editable( GTK_ENTRY( CEChannel4 ),FALSE );
|
|
789 gtk_entry_set_text( GTK_ENTRY( CEChannel5 ),gtkEquChannel5 ); gtk_entry_set_editable( GTK_ENTRY( CEChannel5 ),FALSE );
|
|
790 gtk_entry_set_text( GTK_ENTRY( CEChannel6 ),gtkEquChannel6 ); gtk_entry_set_editable( GTK_ENTRY( CEChannel6 ),FALSE );
|
|
791
|
|
792 gtk_widget_show( EquConfig );
|
6755
|
793 gtkSetLayer( EquConfig );
|
6651
|
794 }
|
|
795
|
|
796 void HideEquConfig( void )
|
|
797 { gtk_widget_hide( EquConfig ); gtk_widget_destroy( EquConfig ); gtkVEquConfig=0; }
|
|
798
|
|
799 static void ecHandler( GtkObject * object,gpointer user_data )
|
|
800 {
|
|
801 switch ( (int)user_data )
|
|
802 {
|
|
803 case 0: HideEquConfig(); break;
|
|
804 case 1: gtkVEquConfig=1; break;
|
|
805 case 2: gtkVEquConfig=0; break;
|
|
806 }
|
|
807 }
|
|
808
|
|
809 static void ecButtonReleased( GtkButton * button,gpointer user_data )
|
|
810 {
|
|
811 if ( (int)user_data )
|
|
812 { // if you pressed Ok
|
|
813 if ( gtkEquChannel1) free( gtkEquChannel1 ); gtkEquChannel1=strdup( gtk_entry_get_text( GTK_ENTRY( CEChannel1 ) ) );
|
|
814 if ( gtkEquChannel2) free( gtkEquChannel2 ); gtkEquChannel2=strdup( gtk_entry_get_text( GTK_ENTRY( CEChannel2 ) ) );
|
|
815 if ( gtkEquChannel3) free( gtkEquChannel3 ); gtkEquChannel3=strdup( gtk_entry_get_text( GTK_ENTRY( CEChannel3 ) ) );
|
|
816 if ( gtkEquChannel4) free( gtkEquChannel4 ); gtkEquChannel4=strdup( gtk_entry_get_text( GTK_ENTRY( CEChannel4 ) ) );
|
|
817 if ( gtkEquChannel5) free( gtkEquChannel5 ); gtkEquChannel5=strdup( gtk_entry_get_text( GTK_ENTRY( CEChannel5 ) ) );
|
|
818 if ( gtkEquChannel6) free( gtkEquChannel6 ); gtkEquChannel6=strdup( gtk_entry_get_text( GTK_ENTRY( CEChannel6 ) ) );
|
|
819 eqSetChannelNames();
|
|
820 }
|
|
821 HideEquConfig();
|
|
822 }
|
|
823
|
|
824 GtkWidget * create_EquConfig( void )
|
|
825 {
|
|
826 GtkWidget * frame1;
|
|
827 GtkWidget * frame2;
|
|
828 GtkWidget * frame3;
|
|
829 GtkWidget * frame4;
|
|
830 GtkWidget * vbox1;
|
|
831 GtkWidget * table1;
|
|
832 GtkWidget * label1;
|
|
833 GtkWidget * label2;
|
|
834 GtkWidget * label3;
|
|
835 GtkWidget * label4;
|
|
836 GtkWidget * label5;
|
|
837 GtkWidget * label6;
|
|
838 GtkWidget * hseparator1;
|
|
839 GtkWidget * hbuttonbox1;
|
|
840 GtkAccelGroup * accel_group;
|
|
841
|
|
842 accel_group=gtk_accel_group_new();
|
|
843
|
|
844 EquConfig=gtk_window_new( GTK_WINDOW_DIALOG );
|
|
845 gtk_widget_set_name( EquConfig,"EquConfig" );
|
|
846 gtk_object_set_data( GTK_OBJECT( EquConfig ),"EquConfig",EquConfig );
|
|
847 gtk_widget_set_usize( EquConfig,350,198 );
|
|
848 GTK_WIDGET_SET_FLAGS( EquConfig,GTK_CAN_DEFAULT );
|
|
849 gtk_window_set_title( GTK_WINDOW( EquConfig ),"Configure Equalizer" );
|
|
850 gtk_window_set_position( GTK_WINDOW( EquConfig ),GTK_WIN_POS_CENTER );
|
|
851 // gtk_window_set_modal( GTK_WINDOW( EquConfig ),TRUE );
|
|
852 gtk_window_set_policy( GTK_WINDOW( EquConfig ),FALSE,FALSE,FALSE );
|
|
853 gtk_window_set_wmclass( GTK_WINDOW( EquConfig ),"EquConfig","MPlayer" );
|
|
854
|
|
855 gtk_widget_realize( EquConfig );
|
|
856 gtkAddIcon( EquConfig );
|
|
857
|
|
858 frame1=gtk_frame_new( NULL );
|
|
859 gtk_widget_set_name( frame1,"frame1" );
|
|
860 gtk_widget_ref( frame1 );
|
|
861 gtk_object_set_data_full( GTK_OBJECT( EquConfig ),"frame1",frame1,(GtkDestroyNotify)gtk_widget_unref );
|
|
862 gtk_widget_show( frame1 );
|
|
863 gtk_container_add( GTK_CONTAINER( EquConfig ),frame1 );
|
|
864 gtk_container_set_border_width( GTK_CONTAINER( frame1 ),1 );
|
|
865 gtk_frame_set_shadow_type( GTK_FRAME( frame1 ),GTK_SHADOW_IN );
|
|
866
|
|
867 frame2=gtk_frame_new( NULL );
|
|
868 gtk_widget_set_name( frame2,"frame2" );
|
|
869 gtk_widget_ref( frame2 );
|
|
870 gtk_object_set_data_full( GTK_OBJECT( EquConfig ),"frame2",frame2,(GtkDestroyNotify)gtk_widget_unref );
|
|
871 gtk_widget_show( frame2 );
|
|
872 gtk_container_add( GTK_CONTAINER( frame1 ),frame2 );
|
|
873 gtk_frame_set_shadow_type( GTK_FRAME( frame2 ),GTK_SHADOW_NONE );
|
|
874
|
|
875 frame3=gtk_frame_new( NULL );
|
|
876 gtk_widget_set_name( frame3,"frame3" );
|
|
877 gtk_widget_ref( frame3 );
|
|
878 gtk_object_set_data_full( GTK_OBJECT( EquConfig ),"frame3",frame3,(GtkDestroyNotify)gtk_widget_unref );
|
|
879 gtk_widget_show( frame3 );
|
|
880 gtk_container_add( GTK_CONTAINER( frame2 ),frame3 );
|
|
881 gtk_frame_set_shadow_type( GTK_FRAME( frame3 ),GTK_SHADOW_ETCHED_OUT );
|
|
882
|
|
883 frame4=gtk_frame_new( NULL );
|
|
884 gtk_widget_set_name( frame4,"frame4" );
|
|
885 gtk_widget_ref( frame4 );
|
|
886 gtk_object_set_data_full( GTK_OBJECT( EquConfig ),"frame4",frame4,(GtkDestroyNotify)gtk_widget_unref );
|
|
887 gtk_widget_show( frame4 );
|
|
888 gtk_container_add( GTK_CONTAINER( frame3 ),frame4 );
|
|
889 gtk_frame_set_shadow_type( GTK_FRAME( frame4 ),GTK_SHADOW_NONE );
|
|
890
|
|
891 vbox1=gtk_vbox_new( FALSE,0 );
|
|
892 gtk_widget_set_name( vbox1,"vbox1" );
|
|
893 gtk_widget_ref( vbox1 );
|
|
894 gtk_object_set_data_full( GTK_OBJECT( EquConfig ),"vbox1",vbox1,(GtkDestroyNotify)gtk_widget_unref );
|
|
895 gtk_widget_show( vbox1 );
|
|
896 gtk_container_add( GTK_CONTAINER( frame4 ),vbox1 );
|
|
897
|
|
898 table1=gtk_table_new( 6,2,FALSE );
|
|
899 gtk_widget_set_name( table1,"table1" );
|
|
900 gtk_widget_ref( table1 );
|
|
901 gtk_object_set_data_full( GTK_OBJECT( EquConfig ),"table1",table1,(GtkDestroyNotify)gtk_widget_unref );
|
|
902 gtk_widget_show( table1 );
|
|
903 gtk_box_pack_start( GTK_BOX( vbox1 ),table1,TRUE,TRUE,0 );
|
|
904 gtk_table_set_row_spacings( GTK_TABLE( table1 ),4 );
|
|
905 gtk_table_set_col_spacings( GTK_TABLE( table1 ),4 );
|
|
906
|
|
907 label1=gtk_label_new( "Channel 1:" );
|
|
908 gtk_widget_set_name( label1,"label1" );
|
|
909 gtk_widget_ref( label1 );
|
|
910 gtk_object_set_data_full( GTK_OBJECT( EquConfig ),"label1",label1,(GtkDestroyNotify)gtk_widget_unref );
|
|
911 gtk_widget_show( label1 );
|
|
912 gtk_table_attach( GTK_TABLE( table1 ),label1,0,1,0,1,(GtkAttachOptions)( GTK_FILL ),(GtkAttachOptions)( 0 ),0,0 );
|
|
913 gtk_misc_set_alignment( GTK_MISC( label1 ),0,0.5 );
|
|
914
|
|
915 label2=gtk_label_new( "Channel 2:" );
|
|
916 gtk_widget_set_name( label2,"label2" );
|
|
917 gtk_widget_ref( label2 );
|
|
918 gtk_object_set_data_full( GTK_OBJECT( EquConfig ),"label2",label2,(GtkDestroyNotify)gtk_widget_unref );
|
|
919 gtk_widget_show( label2 );
|
|
920 gtk_table_attach( GTK_TABLE( table1 ),label2,0,1,1,2,(GtkAttachOptions)( GTK_FILL ),(GtkAttachOptions)( 0 ),0,0 );
|
|
921 gtk_misc_set_alignment( GTK_MISC( label2 ),0,0.5 );
|
|
922
|
|
923 label3=gtk_label_new( "Channel 3:" );
|
|
924 gtk_widget_set_name( label3,"label3" );
|
|
925 gtk_widget_ref( label3 );
|
|
926 gtk_object_set_data_full( GTK_OBJECT( EquConfig ),"label3",label3,(GtkDestroyNotify)gtk_widget_unref );
|
|
927 gtk_widget_show( label3 );
|
|
928 gtk_table_attach( GTK_TABLE( table1 ),label3,0,1,2,3,(GtkAttachOptions)( GTK_FILL ),(GtkAttachOptions)( 0 ),0,0 );
|
|
929 gtk_misc_set_alignment( GTK_MISC( label3 ),0,0.5 );
|
|
930
|
|
931 label4=gtk_label_new( "Channel 4:" );
|
|
932 gtk_widget_set_name( label4,"label4" );
|
|
933 gtk_widget_ref( label4 );
|
|
934 gtk_object_set_data_full( GTK_OBJECT( EquConfig ),"label4",label4,(GtkDestroyNotify)gtk_widget_unref );
|
|
935 gtk_widget_show( label4 );
|
|
936 gtk_table_attach( GTK_TABLE( table1 ),label4,0,1,3,4,(GtkAttachOptions)( GTK_FILL ),(GtkAttachOptions)( 0 ),0,0 );
|
|
937 gtk_misc_set_alignment( GTK_MISC( label4 ),0,0.5 );
|
|
938
|
|
939 label5=gtk_label_new( "Channel 5:" );
|
|
940 gtk_widget_set_name( label5,"label5" );
|
|
941 gtk_widget_ref( label5 );
|
|
942 gtk_object_set_data_full( GTK_OBJECT( EquConfig ),"label5",label5,(GtkDestroyNotify)gtk_widget_unref );
|
|
943 gtk_widget_show( label5 );
|
|
944 gtk_table_attach( GTK_TABLE( table1 ),label5,0,1,4,5,(GtkAttachOptions)( GTK_FILL ),(GtkAttachOptions)( 0 ),0,0 );
|
|
945 gtk_misc_set_alignment( GTK_MISC( label5 ),0,0.5 );
|
|
946
|
|
947 label6=gtk_label_new( "Channel 6:" );
|
|
948 gtk_widget_set_name( label6,"label6" );
|
|
949 gtk_widget_ref( label6 );
|
|
950 gtk_object_set_data_full( GTK_OBJECT( EquConfig ),"label6",label6,(GtkDestroyNotify)gtk_widget_unref );
|
|
951 gtk_widget_show( label6 );
|
|
952 gtk_table_attach( GTK_TABLE( table1 ),label6,0,1,5,6,(GtkAttachOptions)( GTK_FILL ),(GtkAttachOptions)( 0 ),0,0 );
|
|
953 gtk_misc_set_alignment( GTK_MISC( label6 ),0,0.5 );
|
|
954
|
|
955 CBChannel1=gtk_combo_new();
|
|
956 gtk_widget_set_name( CBChannel1,"CBChannel1" );
|
|
957 gtk_widget_ref( CBChannel1 );
|
|
958 gtk_object_set_data_full( GTK_OBJECT( EquConfig ),"CBChannel1",CBChannel1,(GtkDestroyNotify)gtk_widget_unref );
|
|
959 gtk_widget_show( CBChannel1 );
|
|
960 gtk_table_attach( GTK_TABLE( table1 ),CBChannel1,1,2,0,1,(GtkAttachOptions)( GTK_EXPAND | GTK_FILL ),(GtkAttachOptions)( 0 ),0,0 );
|
|
961
|
|
962 CEChannel1=GTK_COMBO( CBChannel1 )->entry;
|
|
963 gtk_widget_set_name( CEChannel1,"CEChannel1" );
|
|
964 gtk_widget_ref( CEChannel1 );
|
|
965 gtk_object_set_data_full( GTK_OBJECT( EquConfig ),"CEChannel1",CEChannel1,(GtkDestroyNotify)gtk_widget_unref );
|
|
966 gtk_widget_show( CEChannel1 );
|
|
967
|
|
968 CBChannel2=gtk_combo_new();
|
|
969 gtk_widget_set_name( CBChannel2,"CBChannel2" );
|
|
970 gtk_widget_ref( CBChannel2 );
|
|
971 gtk_object_set_data_full( GTK_OBJECT( EquConfig ),"CBChannel2",CBChannel2,(GtkDestroyNotify)gtk_widget_unref );
|
|
972 gtk_widget_show( CBChannel2 );
|
|
973 gtk_table_attach( GTK_TABLE( table1 ),CBChannel2,1,2,1,2,(GtkAttachOptions)( GTK_EXPAND | GTK_FILL ),(GtkAttachOptions)( 0 ),0,0 );
|
|
974
|
|
975 CEChannel2=GTK_COMBO( CBChannel2 )->entry;
|
|
976 gtk_widget_set_name( CEChannel2,"CEChannel2" );
|
|
977 gtk_widget_ref( CEChannel2 );
|
|
978 gtk_object_set_data_full( GTK_OBJECT( EquConfig ),"CEChannel2",CEChannel2,(GtkDestroyNotify)gtk_widget_unref );
|
|
979 gtk_widget_show( CEChannel2 );
|
|
980
|
|
981 CBChannel3=gtk_combo_new();
|
|
982 gtk_widget_set_name( CBChannel3,"CBChannel3" );
|
|
983 gtk_widget_ref( CBChannel3 );
|
|
984 gtk_object_set_data_full( GTK_OBJECT( EquConfig ),"CBChannel3",CBChannel3,(GtkDestroyNotify)gtk_widget_unref );
|
|
985 gtk_widget_show( CBChannel3 );
|
|
986 gtk_table_attach( GTK_TABLE( table1 ),CBChannel3,1,2,2,3,(GtkAttachOptions)( GTK_EXPAND | GTK_FILL ),(GtkAttachOptions)( 0 ),0,0 );
|
|
987
|
|
988 CEChannel3=GTK_COMBO( CBChannel3 )->entry;
|
|
989 gtk_widget_set_name( CEChannel3,"CEChannel3" );
|
|
990 gtk_widget_ref( CEChannel3 );
|
|
991 gtk_object_set_data_full( GTK_OBJECT( EquConfig ),"CEChannel3",CEChannel3,(GtkDestroyNotify)gtk_widget_unref );
|
|
992 gtk_widget_show( CEChannel3 );
|
|
993
|
|
994 CBChannel4=gtk_combo_new();
|
|
995 gtk_widget_set_name( CBChannel4,"CBChannel4" );
|
|
996 gtk_widget_ref( CBChannel4 );
|
|
997 gtk_object_set_data_full( GTK_OBJECT( EquConfig ),"CBChannel4",CBChannel4,(GtkDestroyNotify)gtk_widget_unref );
|
|
998 gtk_widget_show( CBChannel4 );
|
|
999 gtk_table_attach( GTK_TABLE( table1 ),CBChannel4,1,2,3,4,(GtkAttachOptions)( GTK_EXPAND | GTK_FILL ),(GtkAttachOptions)( 0 ),0,0 );
|
|
1000
|
|
1001 CEChannel4=GTK_COMBO( CBChannel4 )->entry;
|
|
1002 gtk_widget_set_name( CEChannel4,"CEChannel4" );
|
|
1003 gtk_widget_ref( CEChannel4 );
|
|
1004 gtk_object_set_data_full( GTK_OBJECT( EquConfig ),"CEChannel4",CEChannel4,(GtkDestroyNotify)gtk_widget_unref );
|
|
1005 gtk_widget_show( CEChannel4 );
|
|
1006
|
|
1007 CBChannel5=gtk_combo_new();
|
|
1008 gtk_widget_set_name( CBChannel5,"CBChannel5" );
|
|
1009 gtk_widget_ref( CBChannel5 );
|
|
1010 gtk_object_set_data_full( GTK_OBJECT( EquConfig ),"CBChannel5",CBChannel5,(GtkDestroyNotify)gtk_widget_unref );
|
|
1011 gtk_widget_show( CBChannel5 );
|
|
1012 gtk_table_attach( GTK_TABLE( table1 ),CBChannel5,1,2,4,5,(GtkAttachOptions)( GTK_EXPAND | GTK_FILL ),(GtkAttachOptions)( 0 ),0,0 );
|
|
1013
|
|
1014 CEChannel5=GTK_COMBO( CBChannel5 )->entry;
|
|
1015 gtk_widget_set_name( CEChannel5,"CEChannel5" );
|
|
1016 gtk_widget_ref( CEChannel5 );
|
|
1017 gtk_object_set_data_full( GTK_OBJECT( EquConfig ),"CEChannel5",CEChannel5,(GtkDestroyNotify)gtk_widget_unref );
|
|
1018 gtk_widget_show( CEChannel5 );
|
|
1019
|
|
1020 CBChannel6=gtk_combo_new();
|
|
1021 gtk_widget_set_name( CBChannel6,"CBChannel6" );
|
|
1022 gtk_widget_ref( CBChannel6 );
|
|
1023 gtk_object_set_data_full( GTK_OBJECT( EquConfig ),"CBChannel6",CBChannel6,(GtkDestroyNotify)gtk_widget_unref );
|
|
1024 gtk_widget_show( CBChannel6 );
|
|
1025 gtk_table_attach( GTK_TABLE( table1 ),CBChannel6,1,2,5,6,(GtkAttachOptions)( GTK_EXPAND | GTK_FILL ),(GtkAttachOptions)( 0 ),0,0 );
|
|
1026
|
|
1027 CEChannel6=GTK_COMBO( CBChannel6 )->entry;
|
|
1028 gtk_widget_set_name( CEChannel6,"CEChannel6" );
|
|
1029 gtk_widget_ref( CEChannel6 );
|
|
1030 gtk_object_set_data_full( GTK_OBJECT( EquConfig ),"CEChannel6",CEChannel6,(GtkDestroyNotify)gtk_widget_unref );
|
|
1031 gtk_widget_show( CEChannel6 );
|
|
1032
|
|
1033 hseparator1=gtk_hseparator_new();
|
|
1034 gtk_widget_set_name( hseparator1,"hseparator1" );
|
|
1035 gtk_widget_ref( hseparator1 );
|
|
1036 gtk_object_set_data_full( GTK_OBJECT( EquConfig ),"hseparator1",hseparator1,(GtkDestroyNotify)gtk_widget_unref );
|
|
1037 gtk_widget_show( hseparator1 );
|
|
1038 gtk_box_pack_start( GTK_BOX( vbox1 ),hseparator1,FALSE,FALSE,0 );
|
|
1039 gtk_widget_set_usize( hseparator1,-2,6 );
|
|
1040
|
|
1041 hbuttonbox1=gtk_hbutton_box_new();
|
|
1042 gtk_widget_set_name( hbuttonbox1,"hbuttonbox1" );
|
|
1043 gtk_widget_ref( hbuttonbox1 );
|
|
1044 gtk_object_set_data_full( GTK_OBJECT( EquConfig ),"hbuttonbox1",hbuttonbox1,(GtkDestroyNotify)gtk_widget_unref );
|
|
1045 gtk_widget_show( hbuttonbox1 );
|
|
1046 gtk_box_pack_start( GTK_BOX( vbox1 ),hbuttonbox1,FALSE,FALSE,0 );
|
|
1047 gtk_button_box_set_layout( GTK_BUTTON_BOX( hbuttonbox1 ),GTK_BUTTONBOX_END );
|
|
1048 gtk_button_box_set_spacing( GTK_BUTTON_BOX( hbuttonbox1 ),10 );
|
|
1049 gtk_button_box_set_child_size( GTK_BUTTON_BOX( hbuttonbox1 ),-1,20 );
|
|
1050 gtk_button_box_set_child_ipadding( GTK_BUTTON_BOX( hbuttonbox1 ),0,-1 );
|
|
1051
|
|
1052 ecOk=gtk_button_new_with_label( "Ok" );
|
|
1053 gtk_widget_set_name( ecOk,"Ok" );
|
|
1054 gtk_widget_ref( ecOk );
|
|
1055 gtk_object_set_data_full( GTK_OBJECT( EquConfig ),"ecOk",ecOk,(GtkDestroyNotify)gtk_widget_unref );
|
|
1056 gtk_widget_show( ecOk );
|
|
1057 gtk_container_add( GTK_CONTAINER( hbuttonbox1 ),ecOk );
|
|
1058 GTK_WIDGET_UNSET_FLAGS( ecOk,GTK_CAN_FOCUS );
|
|
1059 gtk_widget_add_accelerator( ecOk,"released",accel_group,GDK_Return,0,GTK_ACCEL_VISIBLE );
|
|
1060
|
|
1061 ecCancel=gtk_button_new_with_label( "Cancel" );
|
|
1062 gtk_widget_set_name( ecCancel,"Cancel" );
|
|
1063 gtk_widget_ref( ecCancel );
|
|
1064 gtk_object_set_data_full( GTK_OBJECT( EquConfig ),"ecCancel",ecCancel,(GtkDestroyNotify)gtk_widget_unref );
|
|
1065 gtk_widget_show( ecCancel );
|
|
1066 gtk_container_add( GTK_CONTAINER( hbuttonbox1 ),ecCancel );
|
|
1067 GTK_WIDGET_UNSET_FLAGS( ecCancel,GTK_CAN_FOCUS );
|
|
1068 gtk_widget_add_accelerator( ecCancel,"released",accel_group,GDK_Escape,0,GTK_ACCEL_VISIBLE );
|
|
1069
|
|
1070 gtk_signal_connect( GTK_OBJECT( EquConfig ),"destroy",GTK_SIGNAL_FUNC( ecHandler ),(void *)0 );
|
|
1071 gtk_signal_connect( GTK_OBJECT( EquConfig ),"show",GTK_SIGNAL_FUNC( ecHandler ),(void *)1 );
|
|
1072 gtk_signal_connect( GTK_OBJECT( EquConfig ),"hide",GTK_SIGNAL_FUNC( ecHandler ),(void *)2 );
|
|
1073
|
|
1074 gtk_signal_connect( GTK_OBJECT( ecOk ),"released",GTK_SIGNAL_FUNC( ecButtonReleased ),(void *)1 );
|
|
1075 gtk_signal_connect( GTK_OBJECT( ecCancel ),"released",GTK_SIGNAL_FUNC( ecButtonReleased ),(void *)0 );
|
|
1076
|
|
1077 gtk_window_add_accel_group( GTK_WINDOW( EquConfig ),accel_group );
|
|
1078
|
|
1079 return EquConfig;
|
|
1080 }
|
|
1081
|