diff options
author | diego <diego@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2009-05-13 02:58:57 +0000 |
---|---|---|
committer | diego <diego@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2009-05-13 02:58:57 +0000 |
commit | 6e9cbdc10448203e7c8b2de41447442fcc9f7bae (patch) | |
tree | 0ed465592509105fdbeab27fc12ddbb2e3590aa5 /gui/mplayer | |
parent | eafe5b7517bbf408ae1ffc936a3abe2313c3b334 (diff) |
whitespace cosmetics: Remove all trailing whitespace.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@29305 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'gui/mplayer')
-rw-r--r-- | gui/mplayer/gtk/about.c | 30 | ||||
-rw-r--r-- | gui/mplayer/gtk/eq.c | 44 | ||||
-rw-r--r-- | gui/mplayer/gtk/gtk_common.c | 2 | ||||
-rw-r--r-- | gui/mplayer/gtk/gtk_url.c | 16 | ||||
-rw-r--r-- | gui/mplayer/gtk/mb.c | 8 | ||||
-rw-r--r-- | gui/mplayer/gtk/menu.c | 24 | ||||
-rw-r--r-- | gui/mplayer/gtk/opts.c | 94 | ||||
-rw-r--r-- | gui/mplayer/gtk/pl.c | 16 | ||||
-rw-r--r-- | gui/mplayer/gtk/sb.c | 2 | ||||
-rw-r--r-- | gui/mplayer/gui_common.c | 10 | ||||
-rw-r--r-- | gui/mplayer/mw.c | 32 | ||||
-rw-r--r-- | gui/mplayer/pb.c | 28 | ||||
-rw-r--r-- | gui/mplayer/play.c | 24 | ||||
-rw-r--r-- | gui/mplayer/sw.c | 2 | ||||
-rw-r--r-- | gui/mplayer/widgets.c | 20 |
15 files changed, 176 insertions, 176 deletions
diff --git a/gui/mplayer/gtk/about.c b/gui/mplayer/gtk/about.c index d14d449e5f..ea3adf0717 100644 --- a/gui/mplayer/gtk/about.c +++ b/gui/mplayer/gtk/about.c @@ -69,7 +69,7 @@ GtkWidget * create_About( void ) gtk_widget_realize( About ); gtkAddIcon( About ); - + vbox=AddVBox( AddDialogFrame( About ),0 ); pixmapstyle=gtk_widget_get_style( About ); @@ -94,8 +94,8 @@ GtkWidget * create_About( void ) gtk_text_view_set_editable(GTK_TEXT_VIEW(AboutText), FALSE); gtk_text_view_set_cursor_visible(GTK_TEXT_VIEW(AboutText), FALSE); AboutTextBuffer = gtk_text_view_get_buffer (GTK_TEXT_VIEW (AboutText)); - gtk_text_buffer_get_iter_at_offset (AboutTextBuffer, &iter, 0); -#else + gtk_text_buffer_get_iter_at_offset (AboutTextBuffer, &iter, 0); +#else AboutText=gtk_text_new( NULL,NULL ); gtk_text_set_editable(GTK_TEXT(AboutText), FALSE); #endif @@ -103,15 +103,15 @@ GtkWidget * create_About( void ) gtk_widget_show( AboutText ); gtk_container_add( GTK_CONTAINER( scrolledwindow1 ),AboutText ); #ifdef CONFIG_GTK2 - gtk_text_buffer_insert (AboutTextBuffer, &iter, -#else + gtk_text_buffer_insert (AboutTextBuffer, &iter, +#else gtk_text_insert( GTK_TEXT( AboutText ),NULL,NULL,NULL, #endif - "\n" - MSGTR_ABOUT_UHU - " (http://www.uhulinux.hu/)\n" - "\n" - MSGTR_ABOUT_Contributors + "\n" + MSGTR_ABOUT_UHU + " (http://www.uhulinux.hu/)\n" + "\n" + MSGTR_ABOUT_Contributors "\n" " * Ackermann, Andreas\n" " * adland\n" @@ -267,8 +267,8 @@ GtkWidget * create_About( void ) " * Zealey, Mark\n" " * Ziv-Av, Matan\n" " * Zoltán, Márk Vicián\n" - "\n" - MSGTR_ABOUT_Codecs_libs_contributions + "\n" + MSGTR_ABOUT_Codecs_libs_contributions "\n" " * Bellard, Fabrice\n" " * Chappelier, Vivien and Vincent, Damien\n" @@ -280,7 +280,7 @@ GtkWidget * create_About( void ) " * Lespinasse, Michel\n" " * Podlipec, Mark\n" "\n" - MSGTR_ABOUT_Translations + MSGTR_ABOUT_Translations "\n" " * Biernat, Marcin\n" " * Fargas, Marc\n" @@ -297,8 +297,8 @@ GtkWidget * create_About( void ) " * Schiller, Wacław\n" " * Zubimendi, Andoni\n" "\n" - MSGTR_ABOUT_Skins - "\n" + MSGTR_ABOUT_Skins + "\n" " * Azrael\n" " * Bekesi, Viktor\n" " * Burt.S.\n" diff --git a/gui/mplayer/gtk/eq.c b/gui/mplayer/gtk/eq.c index 6a5e475344..a344e741ab 100644 --- a/gui/mplayer/gtk/eq.c +++ b/gui/mplayer/gtk/eq.c @@ -91,7 +91,7 @@ static void eqSetBands( int channel ) get_video_colors( guiIntfStruct.sh_video,"hue",&vo_gamma_hue ); get_video_colors( guiIntfStruct.sh_video,"saturation",&vo_gamma_saturation ); } - + gtk_adjustment_set_value( VContrastadj,(float)vo_gamma_contrast ); gtk_adjustment_set_value( VBrightnessadj,(float)vo_gamma_brightness ); gtk_adjustment_set_value( VHueadj,(float)vo_gamma_hue ); @@ -177,7 +177,7 @@ void HideEqualizer( void ) static gboolean eqHScaleMotion( GtkWidget * widget,GdkEventMotion * event,gpointer user_data ) { equalizer_t eq; - switch ( (int)user_data ) + switch ( (int)user_data ) { case 0: eq.gain=A3125adj->value; break; case 1: eq.gain=A6250adj->value; break; @@ -193,13 +193,13 @@ static gboolean eqHScaleMotion( GtkWidget * widget,GdkEventMotion * event,gpoin } eq.gain=0.0f - eq.gain; eq.band=(int)user_data; - if ( Channel == -1 ) + if ( Channel == -1 ) { int i; for ( i=0;i<6;i++ ) { eq.channel=i; gtkSet( gtkSetEqualizer,0,&eq ); } } else { eq.channel=Channel; gtkSet( gtkSetEqualizer,0,&eq ); } - + return FALSE; } @@ -218,16 +218,16 @@ static gboolean eqVScaleMotion( GtkWidget * widget,GdkEventMotion * event,gpoin } static void eqButtonReleased( GtkButton * button,gpointer user_data ) -{ +{ switch( (int)user_data ) { case 0: HideEqualizer(); break; - case 1: + case 1: if ( gtk_notebook_get_current_page( GTK_NOTEBOOK( Notebook ) ) == 0 ) - { + { if ( !guiIntfStruct.Playing || !gtkEnableAudioEqualizer ) break; - gtkSet( gtkSetEqualizer,0,NULL ); - eqSetBands( Channel ); + gtkSet( gtkSetEqualizer,0,NULL ); + eqSetBands( Channel ); } else { @@ -324,7 +324,7 @@ GtkWidget * create_Equalizer( void ) A3125adj=GTK_ADJUSTMENT( gtk_adjustment_new( 0,-eqRange,eqRange,0.5,0,0 ) ); A3125=AddVScaler( A3125adj,NULL,-1 ); gtk_table_attach( GTK_TABLE( table1 ),A3125,0,1,0,1,(GtkAttachOptions)( GTK_FILL ),(GtkAttachOptions)( GTK_EXPAND | GTK_FILL ),0,0 ); - + A6250adj=GTK_ADJUSTMENT( gtk_adjustment_new( 0,-eqRange,eqRange,0.5,0,0 ) ); A6250=AddVScaler( A6250adj,NULL,-1 ); gtk_table_attach( GTK_TABLE( table1 ),A6250,1,2,0,1,(GtkAttachOptions)( GTK_FILL ),(GtkAttachOptions)( GTK_EXPAND | GTK_FILL ),0,0 ); @@ -408,7 +408,7 @@ GtkWidget * create_Equalizer( void ) gtk_widget_set_name( table1,"table1" ); gtk_widget_show( table1 ); gtk_container_add( GTK_CONTAINER( Notebook ),table1 ); - + gtk_table_attach( GTK_TABLE( table1 ), AddLabel( MSGTR_EQU_Contrast,NULL ), 0,1,0,1,(GtkAttachOptions)( GTK_FILL ),(GtkAttachOptions)( 0 ),0,0 ); @@ -457,7 +457,7 @@ GtkWidget * create_Equalizer( void ) Config=AddButton( MSGTR_Config,hbuttonbox1 ); Clear=AddButton( MSGTR_Clear,hbuttonbox1 ); Ok=AddButton( MSGTR_Ok,hbuttonbox1 ); - + gtk_widget_add_accelerator( Ok,"clicked",accel_group,GDK_Escape,0,GTK_ACCEL_VISIBLE ); gtk_widget_add_accelerator( Ok,"clicked",accel_group,GDK_Return,0,GTK_ACCEL_VISIBLE ); @@ -481,7 +481,7 @@ GtkWidget * create_Equalizer( void ) gtk_signal_connect( GTK_OBJECT( VBrightness ),"motion_notify_event",GTK_SIGNAL_FUNC( eqVScaleMotion ),(void*)2 ); gtk_signal_connect( GTK_OBJECT( VHue ),"motion_notify_event",GTK_SIGNAL_FUNC( eqVScaleMotion ),(void*)3 ); gtk_signal_connect( GTK_OBJECT( VSaturation ),"motion_notify_event",GTK_SIGNAL_FUNC( eqVScaleMotion ),(void *)4 ); - + gtk_signal_connect( GTK_OBJECT( Ok ),"clicked",GTK_SIGNAL_FUNC( eqButtonReleased ),(void *)0 ); gtk_signal_connect( GTK_OBJECT( Clear ),"clicked",GTK_SIGNAL_FUNC( eqButtonReleased ),(void *)1 ); gtk_signal_connect( GTK_OBJECT( Config ),"clicked",GTK_SIGNAL_FUNC( eqButtonReleased ),(void *)2 ); @@ -518,14 +518,14 @@ void ShowEquConfig( void ) if ( EquConfig ) gtkActive( EquConfig ); else EquConfig=create_EquConfig(); - + Items=g_list_append( Items,(gpointer)MSGTR_EQU_Front_Right ); Items=g_list_append( Items,(gpointer)MSGTR_EQU_Front_Left ); Items=g_list_append( Items,(gpointer)MSGTR_EQU_Back_Right ); Items=g_list_append( Items,(gpointer)MSGTR_EQU_Back_Left ); Items=g_list_append( Items,(gpointer)MSGTR_EQU_Center ); Items=g_list_append( Items,(gpointer)MSGTR_EQU_Bass ); - + gtk_combo_set_popdown_strings( GTK_COMBO( CBChannel1 ),Items ); gtk_combo_set_popdown_strings( GTK_COMBO( CBChannel2 ),Items ); gtk_combo_set_popdown_strings( GTK_COMBO( CBChannel3 ),Items ); @@ -550,7 +550,7 @@ void HideEquConfig( void ) { if ( !EquConfig ) return; gtk_widget_hide( EquConfig ); - gtk_widget_destroy( EquConfig ); + gtk_widget_destroy( EquConfig ); EquConfig=NULL; } @@ -634,35 +634,35 @@ GtkWidget * create_EquConfig( void ) CBChannel2=AddComboBox( NULL ); gtk_table_attach( GTK_TABLE( table1 ),CBChannel2,1,2,1,2,(GtkAttachOptions)( GTK_EXPAND | GTK_FILL ),(GtkAttachOptions)( 0 ),0,0 ); - + CEChannel2=GTK_COMBO( CBChannel2 )->entry; gtk_widget_set_name( CEChannel2,"CEChannel2" ); gtk_widget_show( CEChannel2 ); CBChannel3=AddComboBox( NULL ); gtk_table_attach( GTK_TABLE( table1 ),CBChannel3,1,2,2,3,(GtkAttachOptions)( GTK_EXPAND | GTK_FILL ),(GtkAttachOptions)( 0 ),0,0 ); - + CEChannel3=GTK_COMBO( CBChannel3 )->entry; gtk_widget_set_name( CEChannel3,"CEChannel3" ); gtk_widget_show( CEChannel3 ); CBChannel4=AddComboBox( NULL ); gtk_table_attach( GTK_TABLE( table1 ),CBChannel4,1,2,3,4,(GtkAttachOptions)( GTK_EXPAND | GTK_FILL ),(GtkAttachOptions)( 0 ),0,0 ); - + CEChannel4=GTK_COMBO( CBChannel4 )->entry; gtk_widget_set_name( CEChannel4,"CEChannel4" ); gtk_widget_show( CEChannel4 ); CBChannel5=AddComboBox( NULL ); gtk_table_attach( GTK_TABLE( table1 ),CBChannel5,1,2,4,5,(GtkAttachOptions)( GTK_EXPAND | GTK_FILL ),(GtkAttachOptions)( 0 ),0,0 ); - + CEChannel5=GTK_COMBO( CBChannel5 )->entry; gtk_widget_set_name( CEChannel5,"CEChannel5" ); gtk_widget_show( CEChannel5 ); CBChannel6=AddComboBox( NULL ); gtk_table_attach( GTK_TABLE( table1 ),CBChannel6,1,2,5,6,(GtkAttachOptions)( GTK_EXPAND | GTK_FILL ),(GtkAttachOptions)( 0 ),0,0 ); - + CEChannel6=GTK_COMBO( CBChannel6 )->entry; gtk_widget_set_name( CEChannel6,"CEChannel6" ); gtk_widget_show( CEChannel6 ); @@ -680,7 +680,7 @@ GtkWidget * create_EquConfig( void ) gtk_widget_add_accelerator( ecCancel,"clicked",accel_group,GDK_Escape,0,GTK_ACCEL_VISIBLE ); gtk_signal_connect( GTK_OBJECT( EquConfig ),"destroy",GTK_SIGNAL_FUNC( WidgetDestroy ),&EquConfig ); - + gtk_signal_connect( GTK_OBJECT( ecOk ),"clicked",GTK_SIGNAL_FUNC( ecButtonReleased ),(void *)1 ); gtk_signal_connect( GTK_OBJECT( ecCancel ),"clicked",GTK_SIGNAL_FUNC( ecButtonReleased ),(void *)0 ); diff --git a/gui/mplayer/gtk/gtk_common.c b/gui/mplayer/gtk/gtk_common.c index 2c7ee9aee3..495a5ea637 100644 --- a/gui/mplayer/gtk/gtk_common.c +++ b/gui/mplayer/gtk/gtk_common.c @@ -71,7 +71,7 @@ GtkWidget * AddVBox( GtkWidget * parent,int type ) vbox=gtk_vbox_new( FALSE,0 ); gtk_widget_set_name( vbox,"vbox" ); gtk_widget_show( vbox ); - if ( parent ) + if ( parent ) { if ( type ) gtk_box_pack_start( GTK_BOX( parent ),vbox,FALSE,FALSE,0 ); else gtk_container_add( GTK_CONTAINER( parent ),vbox ); diff --git a/gui/mplayer/gtk/gtk_url.c b/gui/mplayer/gtk/gtk_url.c index e6385f15ee..4899e801b1 100644 --- a/gui/mplayer/gtk/gtk_url.c +++ b/gui/mplayer/gtk/gtk_url.c @@ -44,7 +44,7 @@ void ShowURLDialogBox( void ) { if ( URL ) gtkActive( URL ); else URL=create_URL(); - + if ( URLList ) { URLItem * item = URLList; @@ -56,13 +56,13 @@ void ShowURLDialogBox( void ) item=item->next; } } - + if ( URLComboEntrys ) { gtk_entry_set_text( GTK_ENTRY( URLEntry ),URLComboEntrys->data ); gtk_combo_set_popdown_strings( GTK_COMBO( URLCombo ),URLComboEntrys ); } - + gtk_widget_show( URL ); } @@ -75,7 +75,7 @@ void HideURLDialogBox( void ) } static void on_Button_pressed( GtkButton * button,gpointer user_data ) -{ +{ URLItem * item; if ( (int)user_data ) @@ -96,7 +96,7 @@ static void on_Button_pressed( GtkButton * button,gpointer user_data ) free( str ); str=tmp; } URLComboEntrys=g_list_prepend( URLComboEntrys,(gchar *)str ); - + item=calloc( 1,sizeof( URLItem ) ); item->url=gstrdup( str ); gtkSet( gtkAddURLItem,0,(void *)item ); @@ -105,7 +105,7 @@ static void on_Button_pressed( GtkButton * button,gpointer user_data ) mplEventHandling( evPlayNetwork,0 ); } } - HideURLDialogBox(); + HideURLDialogBox(); } GtkWidget * create_URL( void ) @@ -128,7 +128,7 @@ GtkWidget * create_URL( void ) gtk_window_set_position( GTK_WINDOW( URL ),GTK_WIN_POS_CENTER ); gtk_window_set_policy( GTK_WINDOW( URL ),TRUE,TRUE,FALSE ); gtk_window_set_wmclass( GTK_WINDOW( URL ),"Network","MPlayer" ); - + gtk_widget_realize( URL ); gtkAddIcon( URL ); @@ -155,7 +155,7 @@ GtkWidget * create_URL( void ) Ok=AddButton( MSGTR_Ok,hbuttonbox1 ); Cancel=AddButton( MSGTR_Cancel,hbuttonbox1 ); - + gtk_widget_add_accelerator( Ok,"clicked",accel_group,GDK_Return,0,GTK_ACCEL_VISIBLE ); gtk_widget_add_accelerator( Cancel,"clicked",accel_group,GDK_Escape,0,GTK_ACCEL_VISIBLE ); diff --git a/gui/mplayer/gtk/mb.c b/gui/mplayer/gtk/mb.c index 4d2a3fa676..76137d629c 100644 --- a/gui/mplayer/gtk/mb.c +++ b/gui/mplayer/gtk/mb.c @@ -38,9 +38,9 @@ void ShowMessageBox( const char * msg ) } static void on_Ok_released( GtkButton * button,gpointer user_data ) -{ - gtk_widget_hide( MessageBox ); - gtk_widget_destroy( MessageBox ); +{ + gtk_widget_hide( MessageBox ); + gtk_widget_destroy( MessageBox ); MessageBox=NULL; } @@ -66,7 +66,7 @@ GtkWidget * create_MessageBox( int type ) gtk_window_set_modal( GTK_WINDOW( MessageBox ),TRUE ); gtk_window_set_policy( GTK_WINDOW( MessageBox ),TRUE,TRUE,FALSE ); gtk_window_set_wmclass( GTK_WINDOW( MessageBox ),"Message","MPlayer" ); - + gtk_widget_realize( MessageBox ); gtkAddIcon( MessageBox ); diff --git a/gui/mplayer/gtk/menu.c b/gui/mplayer/gtk/menu.c index a13e85560a..48736ce81b 100644 --- a/gui/mplayer/gtk/menu.c +++ b/gui/mplayer/gtk/menu.c @@ -102,20 +102,20 @@ static GtkWidget * AddMenuCheckItem(GtkWidget *window1, const char * immagine_xp Item=gtk_check_menu_item_new(); Label = gtk_label_new (label); - + hbox = gtk_hbox_new (FALSE, 8); gtk_box_pack_start (GTK_BOX (hbox), Pixmap, FALSE, FALSE, 0); gtk_box_pack_start (GTK_BOX (hbox), Label, FALSE, FALSE, 0); gtk_container_add (GTK_CONTAINER (Item), hbox); - + gtk_menu_append( GTK_MENU( Menu ),Item ); - + gtk_check_menu_item_set_active(GTK_CHECK_MENU_ITEM(Item),state); gtk_signal_connect_object( GTK_OBJECT(Item),"activate", GTK_SIGNAL_FUNC(ActivateMenuItem),(gpointer)Number ); gtk_menu_item_right_justify (GTK_MENU_ITEM (Item)); gtk_widget_show_all(Item); - + return Item; } GtkWidget * AddMenuItem( GtkWidget *window1, const char * immagine_xpm, GtkWidget * SubMenu,const char * label,int Number ) @@ -174,10 +174,10 @@ GtkWidget * AddSubMenu( GtkWidget *window1, const char * immagine_xpm, GtkWidget gtk_box_pack_start (GTK_BOX (hbox), Pixmap, FALSE, FALSE, 0); gtk_box_pack_start (GTK_BOX (hbox), Label, FALSE, FALSE, 0); gtk_container_add (GTK_CONTAINER (SubItem), hbox); - + gtk_menu_append( GTK_MENU( Menu ),SubItem ); gtk_menu_item_set_submenu( GTK_MENU_ITEM( SubItem ),Item ); - + gtk_widget_show_all( SubItem ); return Item; } @@ -451,7 +451,7 @@ GtkWidget * create_PopUpMenu( void ) AddMenuItem( window1, (const char*)playvcd_xpm, VCDSubMenu,MSGTR_MENU_PlayDisc,evPlayVCD ); AddSeparator( VCDSubMenu ); VCDTitleMenu=AddSubMenu( window1, (const char*)title_xpm, VCDSubMenu,MSGTR_MENU_Titles ); - if ( guiIntfStruct.VCDTracks ) + if ( guiIntfStruct.VCDTracks ) { char tmp[32]; int i; for ( i=0;i < guiIntfStruct.VCDTracks;i++ ) @@ -560,7 +560,7 @@ GtkWidget * create_PopUpMenu( void ) for ( i=0;i < MAX_A_STREAMS;i++ ) if ( ((demuxer_t *)guiIntfStruct.demuxer)->a_streams[i] ) c++; - + if ( c > 1 ) { SubMenu=AddSubMenu( window1, (const char*)empty_xpm, Menu,MSGTR_MENU_AudioTrack ); @@ -576,7 +576,7 @@ GtkWidget * create_PopUpMenu( void ) for ( c=0,i=0;i < MAX_V_STREAMS;i++ ) if ( ((demuxer_t *)guiIntfStruct.demuxer)->v_streams[i] ) c++; - + if ( c > 1 ) { SubMenu=AddSubMenu( window1, (const char*)empty_xpm, Menu,MSGTR_MENU_VideoTrack ); @@ -590,7 +590,7 @@ GtkWidget * create_PopUpMenu( void ) } } } - + /* cheap subtitle switching for non-DVD streams */ if ( global_sub_size && guiIntfStruct.StreamType != STREAMTYPE_DVD ) { @@ -619,9 +619,9 @@ GtkWidget * create_PopUpMenu( void ) AddSeparator( Menu ); if ( !appMPlayer.subWindow.isFullScreen && guiIntfStruct.Playing ) { - if ( ( appMPlayer.subWindow.Width == guiIntfStruct.MovieWidth * 2 )&& + if ( ( appMPlayer.subWindow.Width == guiIntfStruct.MovieWidth * 2 )&& ( appMPlayer.subWindow.Height == guiIntfStruct.MovieHeight * 2 ) ) b2=1; - else if ( ( appMPlayer.subWindow.Width == guiIntfStruct.MovieWidth / 2 ) && + else if ( ( appMPlayer.subWindow.Width == guiIntfStruct.MovieWidth / 2 ) && ( appMPlayer.subWindow.Height == guiIntfStruct.MovieHeight / 2 ) ) b_half=1; else b1=1; } else b1=!appMPlayer.subWindow.isFullScreen; diff --git a/gui/mplayer/gtk/opts.c b/gui/mplayer/gtk/opts.c index 2fe355c5e1..a1c8d226f3 100644 --- a/gui/mplayer/gtk/opts.c +++ b/gui/mplayer/gtk/opts.c @@ -138,7 +138,7 @@ static GtkWidget * CBSubEncoding, * ESubEncoding; #endif #if defined(CONFIG_FREETYPE) || defined(CONFIG_ICONV) -static struct +static struct { char * name; char * comment; @@ -167,12 +167,12 @@ static struct { "shift-jis", MSGTR_PREFERENCES_FontEncoding18 }, { "cp949", MSGTR_PREFERENCES_FontEncoding19 }, { "cp874", MSGTR_PREFERENCES_FontEncoding20 }, - { NULL,NULL } + { NULL,NULL } }; char * lCEncoding = NULL; char * lSEncoding = NULL; #endif - + static int old_audio_driver = 0; static char * ao_driver[3]; static char * vo_driver[3]; @@ -199,7 +199,7 @@ void ShowPreferences( void ) if ( Preferences ) gtkActive( Preferences ); else Preferences=create_Preferences(); -// -- 1. page +// -- 1. page gtk_toggle_button_set_active( GTK_TOGGLE_BUTTON( CBAudioEqualizer ),gtkEnableAudioEqualizer ); #if 0 gtk_toggle_button_set_active( GTK_TOGGLE_BUTTON( CBSurround ),gtkAOSurround ); @@ -259,13 +259,13 @@ void ShowPreferences( void ) { int i = 0, c = 0; char * tmp[3]; tmp[2]=""; - old_video_driver=0; + old_video_driver=0; if ( CLVDrivers ) gtk_clist_clear( GTK_CLIST( CLVDrivers ) ); while ( video_out_drivers[i] ) if ( video_out_drivers[i++]->control( VOCTRL_GUISUPPORT,NULL ) == VO_TRUE ) - { + { if ( video_driver_list && !gstrcmp( video_driver_list[0],(char *)video_out_drivers[i - 1]->info->short_name ) ) old_video_driver=c; c++; - tmp[0]=(char *)video_out_drivers[i - 1]->info->short_name; tmp[1]=(char *)video_out_drivers[i - 1]->info->name; + tmp[0]=(char *)video_out_drivers[i - 1]->info->short_name; tmp[1]=(char *)video_out_drivers[i - 1]->info->name; gtk_clist_append( GTK_CLIST( CLVDrivers ),tmp ); } gtk_clist_select_row( GTK_CLIST( CLVDrivers ),old_video_driver,0 ); @@ -275,7 +275,7 @@ void ShowPreferences( void ) if ( !gstrcmp( vo_driver[0],"dxr3" ) ) gtk_widget_set_sensitive( VConfig,TRUE ); #endif } - + gtk_adjustment_set_value( HSFPSadj,force_fps ); // -- 3. page @@ -316,7 +316,7 @@ void ShowPreferences( void ) if ( sub_cp ) { int i; - for ( i=0;lEncoding[i].name;i++ ) + for ( i=0;lEncoding[i].name;i++ ) if ( !gstrcmp( sub_cp,lEncoding[i].name ) ) break; if ( lEncoding[i].name ) lSEncoding=lEncoding[i].comment; gtk_entry_set_text( GTK_ENTRY( ESubEncoding ),lSEncoding ); @@ -336,7 +336,7 @@ void ShowPreferences( void ) if ( subtitle_font_encoding ) { int i; - for ( i=0;lEncoding[i].name;i++ ) + for ( i=0;lEncoding[i].name;i++ ) if ( !gstrcmp( subtitle_font_encoding,lEncoding[i].name ) ) break; if ( lEncoding[i].name ) lCEncoding=lEncoding[i].comment; gtk_entry_set_text( GTK_ENTRY( EFontEncoding ),lCEncoding ); @@ -409,7 +409,7 @@ void ShowPreferences( void ) gtk_adjustment_set_value( SBCacheadj,(float)gtkCacheSize ); if ( !gtkCacheOn ) gtk_widget_set_sensitive( SBCache,FALSE ); else gtk_toggle_button_set_active( GTK_TOGGLE_BUTTON( CBCache ),TRUE ); - + gtk_toggle_button_set_active( GTK_TOGGLE_BUTTON( CBAutoSync ),0 ); gtk_adjustment_set_value( SBAutoSyncadj,(float)gtkAutoSync ); if ( !gtkAutoSyncOn ) gtk_widget_set_sensitive( SBAutoSync,FALSE ); @@ -464,7 +464,7 @@ void ShowPreferences( void ) gtk_signal_connect( GTK_OBJECT( ESubEncoding ),"changed",GTK_SIGNAL_FUNC( prEntry ),(void *)1 ); #endif gtk_signal_connect( GTK_OBJECT( HSPPQuality ),"motion_notify_event",GTK_SIGNAL_FUNC( prHScaler ),(void*)10 ); - + gtk_signal_connect( GTK_OBJECT( CLADrivers ),"select_row",GTK_SIGNAL_FUNC( prCListRow ),(void*)0 ); gtk_signal_connect( GTK_OBJECT( CLVDrivers ),"select_row",GTK_SIGNAL_FUNC( prCListRow ),(void*)1 ); @@ -472,7 +472,7 @@ void ShowPreferences( void ) gtkSetLayer( Preferences ); { static int visible = 1; - if ( visible ) + if ( visible ) { gtkMessageBox( GTK_MB_WARNING,MSGTR_PREFERENCES_Message ); visible=0; @@ -494,7 +494,7 @@ void HidePreferences( void ) #if defined(CONFIG_FREETYPE) || defined(CONFIG_ICONV) static void prEntry( GtkContainer * container,gpointer user_data ) -{ +{ const char * comment; int i; @@ -556,7 +556,7 @@ void prButton( GtkButton * button,gpointer user_data ) if ( gtk_toggle_button_get_active( GTK_TOGGLE_BUTTON( CBFlip ) ) ) flip=1; force_fps=HSFPSadj->value; - + // -- 3. page suboverlap_enabled=gtk_toggle_button_get_active( GTK_TOGGLE_BUTTON( CBSubOverlap ) ); sub_auto=!gtk_toggle_button_get_active( GTK_TOGGLE_BUTTON( CBNoAutoSub ) ); @@ -576,7 +576,7 @@ void prButton( GtkButton * button,gpointer user_data ) if ( gtk_toggle_button_get_active( GTK_TOGGLE_BUTTON( RBOSDIndicator ) ) ) osd_level=1; if ( gtk_toggle_button_get_active( GTK_TOGGLE_BUTTON( RBOSDTandP ) ) ) osd_level=2; if ( gtk_toggle_button_get_active( GTK_TOGGLE_BUTTON( RBOSDTPTT ) ) ) osd_level=3; - + // --- 4. page guiSetFilename( font_name,gtk_entry_get_text( GTK_ENTRY( prEFontName ) ) ); @@ -602,7 +602,7 @@ void prButton( GtkButton * button,gpointer user_data ) int i; const char * tmp = gtk_entry_get_text( GTK_ENTRY( EVFM ) ); for( i=0;mpcodecs_vd_drivers[i];i++ ) - if ( !gstrcmp( tmp,(char *)mpcodecs_vd_drivers[i]->info->name ) ) + if ( !gstrcmp( tmp,(char *)mpcodecs_vd_drivers[i]->info->name ) ) { gaddlist( &video_fm_list,(char *)mpcodecs_vd_drivers[i]->info->short_name ); break; } } @@ -615,7 +615,7 @@ void prButton( GtkButton * button,gpointer user_data ) } // --- 6. page - gtkVfPP=gtk_toggle_button_get_active( GTK_TOGGLE_BUTTON( CBPostprocess ) ); + gtkVfPP=gtk_toggle_button_get_active( GTK_TOGGLE_BUTTON( CBPostprocess ) ); gtkLoadFullscreen=gtk_toggle_button_get_active( GTK_TOGGLE_BUTTON( CBLoadFullscreen ) ); gui_save_pos=gtk_toggle_button_get_active( GTK_TOGGLE_BUTTON( CBSaveWinPos ) ); gtkShowVideoWindow=gtk_toggle_button_get_active( GTK_TOGGLE_BUTTON( CBShowVideoWindow ) ); @@ -625,7 +625,7 @@ void prButton( GtkButton * button,gpointer user_data ) if ( gtk_toggle_button_get_active( GTK_TOGGLE_BUTTON( CBCache ) ) ) { gtkCacheSize=(int)SBCacheadj->value; gtkCacheOn=1; } else gtkCacheOn=0; - + if ( gtk_toggle_button_get_active( GTK_TOGGLE_BUTTON( CBAutoSync ) ) ) { gtkAutoSync=(int)SBAutoSyncadj->value; gtkAutoSyncOn=1; } else gtkAutoSyncOn=0; @@ -715,14 +715,14 @@ static void prToggled( GtkToggleButton * togglebutton,gpointer user_data ) switch ( (int)user_data ) { case 0: // extra stereo coefficient - if ( guiIntfStruct.Playing ) + if ( guiIntfStruct.Playing ) gtk_widget_set_sensitive( HSExtraStereoMul,gtk_toggle_button_get_active( GTK_TOGGLE_BUTTON( CBExtraStereo ) ) ); break; // case 1: // normalize // case 2: // equalizer // if ( guiIntfStruct.Playing ) gtkMessageBox( GTK_MB_WARNING,"Please remember, this function need restart the playing." ); // break; - case 3: + case 3: if ( gtk_toggle_button_get_active( GTK_TOGGLE_BUTTON( CBShowVideoWindow ) ) ) gtk_widget_set_sensitive( CBLoadFullscreen,TRUE ); else { @@ -774,8 +774,8 @@ static void prCListRow( GtkCList * clist,gint row,gint column,GdkEvent * event,g { switch ( (int)user_data ) { - case 0: // audio driver - gtk_clist_get_text( GTK_CLIST( CLADrivers ),row,0,(char **)&ao_driver ); + case 0: // audio driver + gtk_clist_get_text( GTK_CLIST( CLADrivers ),row,0,(char **)&ao_driver ); gtk_widget_set_sensitive( AConfig,FALSE ); if ( !strncmp( ao_driver[0],"oss",3 ) || !strncmp( ao_driver[0],"alsa",4 ) || @@ -787,14 +787,14 @@ static void prCListRow( GtkCList * clist,gint row,gint column,GdkEvent * event,g gtkMessageBox(GTK_MB_WARNING|GTK_MB_SIMPLE, MSGTR_PREFERENCES_ArtsBroken); #endif break; - case 1: // video driver - gtk_clist_get_text( GTK_CLIST( CLVDrivers ),row,0,(char **)&vo_driver ); + case 1: // video driver + gtk_clist_get_text( GTK_CLIST( CLVDrivers ),row,0,(char **)&vo_driver ); gtk_widget_set_sensitive( VConfig,FALSE ); #ifdef CONFIG_DXR3 if ( !gstrcmp( vo_driver[0],"dxr3" ) ) gtk_widget_set_sensitive( VConfig,TRUE ); #endif break; - } + } } GtkWidget * create_Preferences( void ) @@ -849,7 +849,7 @@ GtkWidget * create_Preferences( void ) gtk_window_set_position( GTK_WINDOW( Preferences ),GTK_WIN_POS_CENTER ); // gtk_window_set_policy( GTK_WINDOW( Preferences ),FALSE,FALSE,FALSE ); gtk_window_set_wmclass( GTK_WINDOW( Preferences ),"Preferences","MPlayer" ); - + gtk_widget_realize( Preferences ); gtkAddIcon( Preferences ); @@ -888,7 +888,7 @@ GtkWidget * create_Preferences( void ) AConfig=AddButton( MSGTR_ConfigDriver, AddHButtonBox( vbox2 ) ); - vbox3=AddVBox( + vbox3=AddVBox( AddFrame( NULL,GTK_SHADOW_NONE, AddFrame( NULL,GTK_SHADOW_ETCHED_OUT,hbox1,0 ),1 ),0 ); gtk_widget_set_usize( vbox3,250,-2 ); @@ -921,7 +921,7 @@ GtkWidget * create_Preferences( void ) hbox2=AddVBox( notebook1,0 ); - vbox4=AddVBox( + vbox4=AddVBox( AddFrame( NULL,GTK_SHADOW_NONE, AddFrame( NULL,GTK_SHADOW_ETCHED_OUT,hbox2,1 ),1 ),0 ); @@ -946,7 +946,7 @@ GtkWidget * create_Preferences( void ) hbuttonbox3=AddHButtonBox( vbox4 ); VConfig=AddButton( MSGTR_ConfigDriver,hbuttonbox3 ); - vbox5=AddVBox( + vbox5=AddVBox( AddFrame( NULL,GTK_SHADOW_NONE, AddFrame( NULL,GTK_SHADOW_ETCHED_OUT,hbox2,0 ),1 ),0 ); gtk_widget_set_usize( vbox5,250,-2 ); @@ -986,7 +986,7 @@ GtkWidget * create_Preferences( void ) vbox6=AddVBox( notebook1,0 ); - vbox600=AddVBox( + vbox600=AddVBox( AddFrame( NULL,GTK_SHADOW_NONE, AddFrame( MSGTR_PREFERENCES_FRAME_OSD_Level,GTK_SHADOW_ETCHED_OUT,vbox6,0 ),1 ),0 ); @@ -995,7 +995,7 @@ GtkWidget * create_Preferences( void ) RBOSDIndicator=AddRadioButton( MSGTR_PREFERENCES_OSDProgress,&OSD_group,vbox600 ); RBOSDTPTT=AddRadioButton( MSGTR_PREFERENCES_OSDTimerPercentageTotalTime,&OSD_group,vbox600 ); - vbox7=AddVBox( + vbox7=AddVBox( AddFrame( NULL,GTK_SHADOW_NONE, AddFrame( MSGTR_PREFERENCES_FRAME_Subtitle,GTK_SHADOW_ETCHED_OUT,vbox6,0 ),1 ),0 ); @@ -1025,7 +1025,7 @@ GtkWidget * create_Preferences( void ) gtk_table_attach( GTK_TABLE( table1 ),label,0,1,0,1,(GtkAttachOptions)( GTK_FILL ),(GtkAttachOptions)( 0 ),0,0 ); label=AddLabel( MSGTR_PREFERENCES_SUB_POS,NULL ); - gtk_table_attach( GTK_TABLE( table1 ),label,0,1,1,2,(GtkAttachOptions)( GTK_FILL ),(GtkAttachOptions)( 0 ),0,0 ); + gtk_table_attach( GTK_TABLE( table1 ),label,0,1,1,2,(GtkAttachOptions)( GTK_FILL ),(GtkAttachOptions)( 0 ),0,0 ); label=AddLabel( MSGTR_PREFERENCES_SUB_FPS,NULL ); gtk_table_attach( GTK_TABLE( table1 ),label,0,1,2,3,(GtkAttachOptions)( GTK_FILL ),(GtkAttachOptions)( 0 ),0,0 ); @@ -1103,7 +1103,7 @@ GtkWidget * create_Preferences( void ) // --- 4. page - vbox603=AddVBox( + vbox603=AddVBox( AddFrame( NULL,GTK_SHADOW_NONE, AddFrame( MSGTR_PREFERENCES_FRAME_Font,GTK_SHADOW_ETCHED_OUT,vbox601,0 ),1 ),0 ); @@ -1136,7 +1136,7 @@ GtkWidget * create_Preferences( void ) label=AddLabel( MSGTR_PREFERENCES_FontEncoding,NULL ); gtk_table_attach( GTK_TABLE( table1 ),label,0,1,0,1,(GtkAttachOptions)( GTK_FILL ),(GtkAttachOptions)( 0 ),0,0 ); - + CBFontEncoding=gtk_combo_new(); gtk_widget_set_name( CBFontEncoding,"CBFontEncoding" ); gtk_widget_show( CBFontEncoding ); @@ -1189,7 +1189,7 @@ GtkWidget * create_Preferences( void ) vbox601=AddVBox( notebook1,0 ); - vbox602=AddVBox( + vbox602=AddVBox( AddFrame( NULL,GTK_SHADOW_NONE, AddFrame( MSGTR_PREFERENCES_FRAME_CodecDemuxer,GTK_SHADOW_ETCHED_OUT,vbox601,0 ),1 ),0 ); @@ -1228,10 +1228,10 @@ GtkWidget * create_Preferences( void ) gtk_notebook_set_tab_label( GTK_NOTEBOOK( notebook1 ),gtk_notebook_get_nth_page( GTK_NOTEBOOK( notebook1 ),4 ),label ); vbox601=AddVBox( notebook1,0 ); - + // --- 6. page - vbox602=AddVBox( + vbox602=AddVBox( AddFrame( NULL,GTK_SHADOW_NONE, AddFrame( MSGTR_PREFERENCES_FRAME_PostProcess,GTK_SHADOW_ETCHED_OUT,vbox601,0 ),1 ),0 ); @@ -1245,12 +1245,12 @@ GtkWidget * create_Preferences( void ) else HSPPQualityadj=GTK_ADJUSTMENT( gtk_adjustment_new( 0,0,100,0,0,0 ) ); HSPPQuality=AddHScaler( HSPPQualityadj,hbox5,0 ); - vbox602=AddVBox( + vbox602=AddVBox( AddFrame( NULL,GTK_SHADOW_NONE, AddFrame( MSGTR_PREFERENCES_FRAME_Cache,GTK_SHADOW_ETCHED_OUT,vbox601,0 ),1 ),0 ); CBCache=AddCheckButton( MSGTR_PREFERENCES_Cache,vbox602 ); - + hbox5=AddHBox( vbox602,1 ); AddLabel( MSGTR_PREFERENCES_CacheSize,hbox5 ); @@ -1260,7 +1260,7 @@ GtkWidget * create_Preferences( void ) gtk_widget_show( SBCache ); gtk_box_pack_start( GTK_BOX( hbox5 ),SBCache,TRUE,TRUE,0 ); - vbox602=AddVBox( + vbox602=AddVBox( AddFrame( NULL,GTK_SHADOW_NONE, AddFrame( MSGTR_PREFERENCES_FRAME_Misc,GTK_SHADOW_ETCHED_OUT,vbox601,1 ),1 ),0 ); @@ -1315,12 +1315,12 @@ GtkWidget * create_Preferences( void ) gtk_button_box_set_spacing( GTK_BUTTON_BOX( hbuttonbox1 ),10 ); BOk=AddButton( MSGTR_Ok,hbuttonbox1 ); BCancel=AddButton( MSGTR_Cancel,hbuttonbox1 ); - + gtk_widget_add_accelerator( BOk,"clicked",accel_group,GDK_Return,0,GTK_ACCEL_VISIBLE ); gtk_widget_add_accelerator( BCancel,"clicked",accel_group,GDK_Escape,0,GTK_ACCEL_VISIBLE ); gtk_signal_connect( GTK_OBJECT( Preferences ),"destroy",GTK_SIGNAL_FUNC( WidgetDestroy ),&Preferences ); - + gtk_signal_connect( GTK_OBJECT( AConfig ),"clicked",GTK_SIGNAL_FUNC( prButton ),(void*)bAConfig ); gtk_signal_connect( GTK_OBJECT( BOk ),"clicked",GTK_SIGNAL_FUNC( prButton ),(void*)bOk ); gtk_signal_connect( GTK_OBJECT( BCancel ),"clicked",GTK_SIGNAL_FUNC( prButton ),(void*)bCancel ); @@ -1470,7 +1470,7 @@ GList *appendESDDevices(GList *l) { } #endif -// Gets text string from a gtk entry, interpreting +// Gets text string from a gtk entry, interpreting // MSGTR_PREFERENCES_DriverDefault as null string. const char *getGtkEntryText(GtkWidget *from) { const char *tmp = gtk_entry_get_text(GTK_ENTRY(from)); @@ -1480,7 +1480,7 @@ const char *getGtkEntryText(GtkWidget *from) { return tmp; } -// Sets text string of a gtk entry, interpreting +// Sets text string of a gtk entry, interpreting // null string as MSGTR_PREFERENCES_DriverDefault. void setGtkEntryText(GtkWidget *dest, char *to) { if (!to) { @@ -1535,7 +1535,7 @@ void ShowAudioConfig( void ) { void HideAudioConfig( void ) { if (!AudioConfig) return; gtk_widget_hide(AudioConfig); - gtk_widget_destroy(AudioConfig); + gtk_widget_destroy(AudioConfig); AudioConfig=NULL; } @@ -1820,7 +1820,7 @@ GtkWidget * create_DXR3Config( void ) gtk_widget_add_accelerator( dxr3BCancel,"clicked",accel_group,GDK_Escape,0,GTK_ACCEL_VISIBLE ); gtk_signal_connect( GTK_OBJECT( DXR3Config ),"destroy",GTK_SIGNAL_FUNC( WidgetDestroy ),&DXR3Config ); - + gtk_signal_connect( GTK_OBJECT( dxr3BOk ),"clicked",GTK_SIGNAL_FUNC( dxr3Button ),(void *)0 ); gtk_signal_connect( GTK_OBJECT( dxr3BCancel ),"clicked",GTK_SIGNAL_FUNC( dxr3Button ),(void *)1 ); diff --git a/gui/mplayer/gtk/pl.c b/gui/mplayer/gtk/pl.c index 58b03d2eaa..2dade2bbc3 100644 --- a/gui/mplayer/gtk/pl.c +++ b/gui/mplayer/gtk/pl.c @@ -153,7 +153,7 @@ void ShowPlayList( void ) pos=strtok( NULL,"/" ); gtk_ctree_get_node_info( GTK_CTREE( CTDirTree ),node,NULL,NULL,NULL,NULL,NULL,NULL,&leaf,NULL ); if ( !leaf && pos ) gtk_ctree_expand( GTK_CTREE( CTDirTree ),node ); - else + else { DirNodeType * DirNode; gtk_ctree_select( GTK_CTREE( CTDirTree ),node ); @@ -247,7 +247,7 @@ static void plButtonReleased( GtkButton * button,gpointer user_data ) } } case 0: // cancel - HidePlayList(); + HidePlayList(); break; case 2: // remove { @@ -258,7 +258,7 @@ static void plButtonReleased( GtkButton * button,gpointer user_data ) gtk_clist_freeze( GTK_CLIST( CLSelected ) ); for ( i=0;i<NrOfSelected-c;i++ ) - if ( CLListSelected[i] ) + if ( CLListSelected[i] ) { gtk_clist_remove( GTK_CLIST( CLSelected ),i - c ); c++; @@ -341,7 +341,7 @@ static void plCTree( GtkCTree * ctree,GtkCTreeNode * parent_node,gpointer user_d gtk_clist_freeze( GTK_CLIST( ctree ) ); node=gtk_ctree_find_by_row_data( ctree,parent_node,NULL ); gtk_ctree_remove_node( ctree,node ); - + if ( (dir=opendir( DirNode->path ) ) ) { while( (dirent=readdir( dir )) ) @@ -363,7 +363,7 @@ static void plCTree( GtkCTree * ctree,GtkCTreeNode * parent_node,gpointer user_d } closedir( dir ); } - + gtk_ctree_sort_node( ctree,parent_node ); gtk_clist_thaw( GTK_CLIST( ctree ) ); } @@ -443,7 +443,7 @@ GtkWidget * create_PlayList( void ) scrolledwindow1=gtk_scrolled_window_new( NULL,NULL ); gtk_widget_show( scrolledwindow1 ); - gtk_container_add( GTK_CONTAINER( + gtk_container_add( GTK_CONTAINER( AddFrame( NULL,0,hbox1,1 ) ),scrolledwindow1 ); gtk_scrolled_window_set_policy( GTK_SCROLLED_WINDOW( scrolledwindow1 ),GTK_POLICY_AUTOMATIC,GTK_POLICY_AUTOMATIC ); @@ -469,10 +469,10 @@ GtkWidget * create_PlayList( void ) gtk_ctree_expand( GTK_CTREE( CTDirTree ),parent ); gtk_widget_show( CTDirTree ); - + gtk_clist_set_column_widget( GTK_CLIST( CTDirTree ),0, AddLabel( MSGTR_PLAYLIST_DirectoryTree,NULL ) ); - + vbox2=AddVBox( AddFrame( NULL,1,hbox1,1 ),0 ); diff --git a/gui/mplayer/gtk/sb.c b/gui/mplayer/gtk/sb.c index 3709de42af..7b793a73b3 100644 --- a/gui/mplayer/gtk/sb.c +++ b/gui/mplayer/gtk/sb.c @@ -104,7 +104,7 @@ static void prButton( GtkObject * object,gpointer user_data ) ChangeSkin( sbSelectedSkin ); if ( skinName ) free( skinName ); skinName=strdup( sbSelectedSkin ); - break; + break; } } HideSkinBrowser(); diff --git a/gui/mplayer/gui_common.c b/gui/mplayer/gui_common.c index d6df8b0f39..646b76929b 100644 --- a/gui/mplayer/gui_common.c +++ b/gui/mplayer/gui_common.c @@ -54,7 +54,7 @@ static inline void TranslateFilename( int c,char * tmp,size_t tmplen ) { int i; char * p; - + switch ( guiIntfStruct.StreamType ) { case STREAMTYPE_STREAM: @@ -214,16 +214,16 @@ void PutImage( txSample * bf,int x,int y,int max,int ofs ) for ( iy=y;iy < (int)(y+bf->Height / max);iy++ ) for ( ix=x;ix < (int)(x+bf->Width);ix++ ) { - tmp=drw[i++]; + tmp=drw[i++]; if ( tmp != 0x00ff00ff ) buf[iy * image_width + ix]=tmp; } #else - yc=y * image_width; + yc=y * image_width; for ( iy=y;iy < (int)(y+bf->Height / max);iy++ ) { for ( ix=x;ix < (int)(x+bf->Width);ix++ ) { - tmp=drw[i++]; + tmp=drw[i++]; if ( tmp != 0x00ff00ff ) buf[yc + ix]=tmp; } yc+=image_width; @@ -248,7 +248,7 @@ void SimplePotmeterPutImage( txSample * bf,int x,int y,float frac ) { for ( ix=x;ix < (int)(x+w);ix++ ) { - tmp=drw[i++]; + tmp=drw[i++]; if ( tmp != 0x00ff00ff ) buf[iy * image_width + ix]=tmp; } i+=r; diff --git a/gui/mplayer/mw.c b/gui/mplayer/mw.c index 1d9dfbedc8..4e64af3a51 100644 --- a/gui/mplayer/mw.c +++ b/gui/mplayer/mw.c @@ -73,7 +73,7 @@ void mplMainDraw( void ) { if ( appMPlayer.mainWindow.State == wsWindowClosed ) exit_player( MSGTR_Exit_quit ); - + if ( appMPlayer.mainWindow.Visible == wsWindowNotVisible || !mainVisible ) return; // !appMPlayer.mainWindow.Mapped ) return; @@ -125,7 +125,7 @@ void mplEventHandling( int msg,float param ) goto play; case evSetSubtitle: - mp_property_do("sub",M_PROPERTY_SET,&iparam,guiIntfStruct.mpcontext); + mp_property_do("sub",M_PROPERTY_SET,&iparam,guiIntfStruct.mpcontext); break; #ifdef CONFIG_VCD @@ -192,7 +192,7 @@ play: guiIntfStruct.Chapter=guiIntfStruct.DVD.current_chapter; guiIntfStruct.Angle=guiIntfStruct.DVD.current_angle; guiIntfStruct.DiskChanged=1; - } + } break; #endif } @@ -226,9 +226,9 @@ NoPause: mplPause(); break; - case evStop: - guiIntfStruct.Playing=guiSetStop; - mplState(); + case evStop: + guiIntfStruct.Playing=guiSetStop; + mplState(); guiIntfStruct.NoWindow=False; break; @@ -269,7 +269,7 @@ NoPause: case evSetVolume: guiIntfStruct.Volume=param; goto set_volume; - case evSetBalance: + case evSetBalance: guiIntfStruct.Balance=param; set_volume: { @@ -358,7 +358,7 @@ set_volume: wsClearWindow( appMPlayer.subWindow ); #ifdef CONFIG_DVDREAD if ( guiIntfStruct.StreamType == STREAMTYPE_DVD || guiIntfStruct.StreamType == STREAMTYPE_VCD ) goto play_dvd_2; - else + else #endif guiIntfStruct.NewPlay=1; break; @@ -424,7 +424,7 @@ void mplMainMouseHandle( int Button,int X,int Y,int RX,int RY ) sx=X; sy=Y; boxMoved=1; itemtype=itPLMButton; SelectedItem=currentselected; if ( SelectedItem == -1 ) break; - boxMoved=0; + boxMoved=0; item=&appMPlayer.Items[SelectedItem]; itemtype=item->type; item->pressed=btnPressed; @@ -517,7 +517,7 @@ void mplMainKeyHandle( int KeyCode,int Type,int Key ) int msg = evNone; if ( Type != wsKeyPressed ) return; - + if ( !Key ) { switch ( KeyCode ) @@ -544,11 +544,11 @@ void mplMainKeyHandle( int KeyCode,int Type,int Key ) case wsXF86Prev: msg=evPrev; break; case wsXF86Next: msg=evNext; break; case wsXF86Media: msg=evLoad; break; - case wsEscape: + case wsEscape: if ( appMPlayer.subWindow.isFullScreen ) - { - if ( guiIntfStruct.event_struct ) ((XEvent *)guiIntfStruct.event_struct)->type=None; - mplEventHandling( evNormalSize,0 ); + { + if ( guiIntfStruct.event_struct ) ((XEvent *)guiIntfStruct.event_struct)->type=None; + mplEventHandling( evNormalSize,0 ); return; } default: vo_x11_putkey( Key ); return; @@ -580,7 +580,7 @@ void mplDandDHandler(int num,char** files) if(stat(str,&buf) == 0 && S_ISDIR(buf.st_mode) == 0) { /* this is not a directory so try to play it */ mp_msg( MSGT_GPLAYER,MSGL_V,"Received D&D %s\n",str ); - + /* check if it is a subtitle file */ { char* ext = strrchr(str,'.'); @@ -605,7 +605,7 @@ void mplDandDHandler(int num,char** files) } item = calloc(1,sizeof(plItem)); - + /* FIXME: decompose file name ? */ /* yes -- Pontscho */ if ( strrchr( str,'/' ) ) { diff --git a/gui/mplayer/pb.c b/gui/mplayer/pb.c index 65f28289fe..9238755d91 100644 --- a/gui/mplayer/pb.c +++ b/gui/mplayer/pb.c @@ -59,7 +59,7 @@ int mplPBFade = 0; void mplPBDraw( void ) { int x; - + if ( !appMPlayer.subWindow.isFullScreen ) return; if ( !mplPBVisible || !appMPlayer.barIsPresent ) return; @@ -70,7 +70,7 @@ void mplPBDraw( void ) case -2: x=( appMPlayer.subWindow.Width - appMPlayer.bar.width ); break; default: x=appMPlayer.bar.x; } - + switch ( mplPBFade ) { case 1: // fade in @@ -81,7 +81,7 @@ void mplPBDraw( void ) mplPBFade=0; vo_mouse_autohide=0; } - wsMoveWindow( &appMPlayer.barWindow,0,x,mplPBLength ); + wsMoveWindow( &appMPlayer.barWindow,0,x,mplPBLength ); break; case 2: // fade out mplPBLength+=10; @@ -89,11 +89,11 @@ void mplPBDraw( void ) { mplPBLength=appMPlayer.subWindow.Height; mplPBFade=mplPBVisible=0; - vo_mouse_autohide=1; - wsVisibleWindow( &appMPlayer.barWindow,wsHideWindow ); + vo_mouse_autohide=1; + wsVisibleWindow( &appMPlayer.barWindow,wsHideWindow ); return; } - wsMoveWindow( &appMPlayer.barWindow,0,x,mplPBLength ); + wsMoveWindow( &appMPlayer.barWindow,0,x,mplPBLength ); break; } @@ -102,12 +102,12 @@ void mplPBDraw( void ) { btnModify( evSetMoviePosition,guiIntfStruct.Position ); btnModify( evSetVolume,guiIntfStruct.Volume ); - + vo_mouse_autohide=0; fast_memcpy( mplPBDrawBuffer,appMPlayer.bar.Bitmap.Image,appMPlayer.bar.Bitmap.ImageSize ); Render( &appMPlayer.barWindow,appMPlayer.barItems,appMPlayer.NumberOfBarItems,mplPBDrawBuffer,appMPlayer.bar.Bitmap.ImageSize ); - wsConvert( &appMPlayer.barWindow,mplPBDrawBuffer,appMPlayer.bar.Bitmap.ImageSize ); + wsConvert( &appMPlayer.barWindow,mplPBDrawBuffer,appMPlayer.bar.Bitmap.ImageSize ); } wsPutImage( &appMPlayer.barWindow ); } @@ -121,7 +121,7 @@ void mplPBMouseHandle( int Button,int X,int Y,int RX,int RY ) int i; wItem * item = NULL; float value = 0.0f; - + static int SelectedItem = -1; int currentselected = -1; @@ -129,7 +129,7 @@ void mplPBMouseHandle( int Button,int X,int Y,int RX,int RY ) if ( ( appMPlayer.barItems[i].pressed != btnDisabled )&& ( wgIsRect( X,Y,appMPlayer.barItems[i].x,appMPlayer.barItems[i].y,appMPlayer.barItems[i].x+appMPlayer.barItems[i].width,appMPlayer.barItems[i].y+appMPlayer.barItems[i].height ) ) ) { currentselected=i; break; } - + switch ( Button ) { case wsPMMouseButton: @@ -230,8 +230,8 @@ void mplPBShow( int x, int y ) if ( !appMPlayer.barIsPresent || !gtkEnablePlayBar ) return; if ( !appMPlayer.subWindow.isFullScreen ) return; - if ( y > appMPlayer.subWindow.Height - appMPlayer.bar.height ) - { + if ( y > appMPlayer.subWindow.Height - appMPlayer.bar.height ) + { if ( !mplPBFade ) wsVisibleWindow( &appMPlayer.barWindow,wsShowWindow ); mplPBFade=1; mplPBVisible=1; wsPostRedisplay( &appMPlayer.barWindow ); } @@ -256,10 +256,10 @@ void mplPBInit( void ) wsNoBorder,wsShowMouseCursor|wsHandleMouseButton|wsHandleMouseMove,wsHideFrame|wsHideWindow,"PlayBar" ); wsSetShape( &appMPlayer.barWindow,appMPlayer.bar.Mask.Image ); - + appMPlayer.barWindow.ReDraw=(void *)mplPBDraw; appMPlayer.barWindow.MouseHandler=mplPBMouseHandle; appMPlayer.barWindow.KeyHandler=mplMainKeyHandle; - + mplPBLength=appMPlayer.subWindow.Height; } diff --git a/gui/mplayer/play.c b/gui/mplayer/play.c index 63b639d5d1..b398f9f901 100644 --- a/gui/mplayer/play.c +++ b/gui/mplayer/play.c @@ -56,8 +56,8 @@ void mplFullScreen( void ) if ( guiIntfStruct.NoWindow && guiIntfStruct.Playing ) return; if ( ( guiIntfStruct.Playing )&&( appMPlayer.subWindow.isFullScreen ) ) - { - appMPlayer.subWindow.OldWidth=guiIntfStruct.MovieWidth; appMPlayer.subWindow.OldHeight=guiIntfStruct.MovieHeight; + { + appMPlayer.subWindow.OldWidth=guiIntfStruct.MovieWidth; appMPlayer.subWindow.OldHeight=guiIntfStruct.MovieHeight; switch ( appMPlayer.sub.x ) { case -1: appMPlayer.subWindow.OldX=( wsMaxX / 2 ) - ( appMPlayer.subWindow.OldWidth / 2 ) + wsOrgX; break; @@ -94,7 +94,7 @@ void mplEnd( void ) guiIntfStruct.FilenameChanged=guiIntfStruct.NewPlay=1; gfree( (void **)&guiIntfStruct.AudioFile ); gfree( (void **)&guiIntfStruct.Subtitlename ); - } + } else { if ( guiIntfStruct.FilenameChanged || guiIntfStruct.NewPlay ) return; @@ -187,7 +187,7 @@ void ChangeSkin( char * name ) int bprev = appMPlayer.barIsPresent; mainVisible=0; - + appInitStruct( &tmpList ); skinAppMPlayer=&tmpList; fntFreeFont(); @@ -268,13 +268,13 @@ void ChangeSkin( char * name ) wsSetLayer( wsDisplay,appMPlayer.mainWindow.WindowID,appMPlayer.subWindow.isFullScreen ); wsSetLayer( wsDisplay,appMPlayer.menuWindow.WindowID,appMPlayer.subWindow.isFullScreen ); - + } void mplSetFileName( char * dir,char * name,int type ) { if ( !name ) return; - + if ( !dir ) guiSetFilename( guiIntfStruct.Filename,name ) else guiSetDF( guiIntfStruct.Filename,dir,name ); @@ -288,7 +288,7 @@ void mplCurr( void ) { plItem * curr; int stop = 0; - + if ( guiIntfStruct.Playing == 2 ) return; switch ( guiIntfStruct.StreamType ) { @@ -300,7 +300,7 @@ void mplCurr( void ) case STREAMTYPE_VCD: break; #endif - default: + default: if ( (curr=gtkSet( gtkGetCurrPlItem,0,NULL)) ) { mplSetFileName( curr->path,curr->name,STREAMTYPE_FILE ); @@ -318,7 +318,7 @@ void mplPrev( void ) { plItem * prev; int stop = 0; - + if ( guiIntfStruct.Playing == 2 ) return; switch ( guiIntfStruct.StreamType ) { @@ -337,7 +337,7 @@ void mplPrev( void ) if ( --guiIntfStruct.Track == 0 ) { guiIntfStruct.Track=1; stop=1; } break; #endif - default: + default: if ( (prev=gtkSet( gtkGetPrevPlItem,0,NULL)) ) { mplSetFileName( prev->path,prev->name,STREAMTYPE_FILE ); @@ -374,8 +374,8 @@ void mplNext( void ) break; #endif default: - if ( (next=gtkSet( gtkGetNextPlItem,0,NULL)) ) - { + if ( (next=gtkSet( gtkGetNextPlItem,0,NULL)) ) + { mplSetFileName( next->path,next->name,STREAMTYPE_FILE ); mplGotoTheNext=0; break; diff --git a/gui/mplayer/sw.c b/gui/mplayer/sw.c index e31fda83fb..349847b5b8 100644 --- a/gui/mplayer/sw.c +++ b/gui/mplayer/sw.c @@ -40,7 +40,7 @@ extern int i,pot; void mplSubDraw( void ) { if ( appMPlayer.subWindow.State == wsWindowClosed ) exit_player( MSGTR_Exit_quit ); - + if ( appMPlayer.subWindow.State == wsWindowFocusIn ) SubVisible++; if ( appMPlayer.subWindow.State == wsWindowFocusOut && metacity_hack != 3 ) SubVisible--; diff --git a/gui/mplayer/widgets.c b/gui/mplayer/widgets.c index 0cf3c1fbd9..d6b0442303 100644 --- a/gui/mplayer/widgets.c +++ b/gui/mplayer/widgets.c @@ -86,7 +86,7 @@ void gtkInit( void ) GtkWidget * win; win=gtk_window_new( GTK_WINDOW_TOPLEVEL ); - if ( !gtkIcon ) + if ( !gtkIcon ) gtkIcon=gdk_pixmap_colormap_create_from_xpm_d( win->window,gdk_colormap_get_system(),>kIconMask,&win->style->bg[GTK_STATE_NORMAL],MPlayer_mini_xpm ); guiIcon=GDK_WINDOW_XWINDOW( gtkIcon ); @@ -94,7 +94,7 @@ void gtkInit( void ) gtk_widget_destroy( win ); } - + gtkInitialized=1; } @@ -166,7 +166,7 @@ void gtkMessageBox( int type,const gchar * str ) } void gtkSetLayer( GtkWidget * wdg ) -{ +{ wsSetLayer( gdk_display,GDK_WINDOW_XWINDOW( wdg->window ),appMPlayer.subWindow.isFullScreen ); gtkActive( wdg ); } @@ -194,8 +194,8 @@ void gtkShow( int type,char * param ) gtk_clist_sort( GTK_CLIST( SkinList ) ); gtk_widget_show( SkinBrowser ); gtkSetLayer( SkinBrowser ); - } - else + } + else { gtk_widget_destroy( SkinBrowser ); gtkMessageBox( GTK_MB_ERROR,"Skin dirs not found ... Please install skins." ); @@ -231,20 +231,20 @@ void gtkShow( int type,char * param ) case evShowPopUpMenu: gtkPopupMenu=evNone; gtkPopupMenuParam=0; - if ( PopUpMenu ) - { - gtk_widget_hide( PopUpMenu ); + if ( PopUpMenu ) + { + gtk_widget_hide( PopUpMenu ); gtk_widget_destroy( PopUpMenu ); } PopUpMenu=create_PopUpMenu(); gtk_menu_popup( GTK_MENU( PopUpMenu ),NULL,NULL,NULL,NULL,0,0 ); break; case evHidePopUpMenu: - if ( PopUpMenu ) + if ( PopUpMenu ) { gtk_widget_hide( PopUpMenu ); gtk_widget_destroy( PopUpMenu ); - PopUpMenu=NULL; + PopUpMenu=NULL; } break; case evPlayNetwork: |