changeset 35975:16f60d1a3b7f

Rename extern GTK widget fsFileSelect FileSelector.
author ib
date Thu, 28 Mar 2013 16:35:59 +0000
parents 3ccb13092e88
children 6eaf7941b762
files gui/dialog/dialog.c gui/dialog/fileselect.c gui/dialog/fileselect.h gui/dialog/preferences.c
diffstat 4 files changed, 42 insertions(+), 42 deletions(-) [+]
line wrap: on
line diff
--- a/gui/dialog/dialog.c	Thu Mar 28 16:23:39 2013 +0000
+++ b/gui/dialog/dialog.c	Thu Mar 28 16:35:59 2013 +0000
@@ -326,17 +326,17 @@
 
     case evLoad:
         ShowFileSelect(FILESELECT_VIDEO_AUDIO, 0);
-        gtkSetLayer(fsFileSelect);
+        gtkSetLayer(FileSelector);
         break;
 
     case evLoadSubtitle:
         ShowFileSelect(FILESELECT_SUBTITLE, 0);
-        gtkSetLayer(fsFileSelect);
+        gtkSetLayer(FileSelector);
         break;
 
     case evLoadAudioFile:
         ShowFileSelect(FILESELECT_AUDIO, 0);
-        gtkSetLayer(fsFileSelect);
+        gtkSetLayer(FileSelector);
         break;
 
     case evAbout:
--- a/gui/dialog/fileselect.c	Thu Mar 28 16:23:39 2013 +0000
+++ b/gui/dialog/fileselect.c	Thu Mar 28 16:35:59 2013 +0000
@@ -142,7 +142,7 @@
 
 GtkWidget   * fsFileNamesList;
 GtkWidget   * fsFNameList;
-GtkWidget   * fsFileSelect = NULL;
+GtkWidget   * FileSelector = NULL;
 GdkColormap * fsColorMap;
 GtkWidget   * fsOk;
 GtkWidget   * fsUp;
@@ -276,10 +276,10 @@
 
 static void HideFileSelect( void )
 {
- if ( !fsFileSelect ) return;
- gtk_widget_hide( fsFileSelect );
- gtk_widget_destroy( fsFileSelect );
- fsFileSelect=NULL;
+ if ( !FileSelector ) return;
+ gtk_widget_hide( FileSelector );
+ gtk_widget_destroy( FileSelector );
+ FileSelector=NULL;
  fsLastFNameListSelected = fsCurrFNameListSelected;
 }
 
@@ -514,7 +514,7 @@
 
 static void fs_Destroy( void )
 {
- WidgetDestroy( fsFileSelect, &fsFileSelect );
+ WidgetDestroy( FileSelector, &FileSelector );
 
  g_hash_table_destroy( fsPathTable );
 
@@ -538,26 +538,26 @@
  GtkStyle      * upstyle;
 
 
- fsFileSelect=gtk_window_new( GTK_WINDOW_TOPLEVEL );
- gtk_widget_set_name( fsFileSelect,"fsFileSelect" );
- gtk_object_set_data( GTK_OBJECT( fsFileSelect ),"fsFileSelect",fsFileSelect );
- gtk_widget_set_usize( fsFileSelect,512,300 );
- GTK_WIDGET_SET_FLAGS( fsFileSelect,GTK_CAN_DEFAULT );
- gtk_widget_set_events( fsFileSelect,GDK_EXPOSURE_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK | GDK_KEY_PRESS_MASK | GDK_KEY_RELEASE_MASK | GDK_FOCUS_CHANGE_MASK | GDK_STRUCTURE_MASK | GDK_PROPERTY_CHANGE_MASK | GDK_VISIBILITY_NOTIFY_MASK );
- gtk_window_set_title( GTK_WINDOW( fsFileSelect ),MSGTR_FileSelect );
- gtk_window_set_position( GTK_WINDOW( fsFileSelect ),GTK_WIN_POS_CENTER );
- gtk_window_set_policy( GTK_WINDOW( fsFileSelect ),TRUE,TRUE,TRUE );
- gtk_window_set_wmclass( GTK_WINDOW( fsFileSelect ),"FileSelect","MPlayer" );
+ FileSelector=gtk_window_new( GTK_WINDOW_TOPLEVEL );
+ gtk_widget_set_name( FileSelector,"FileSelector" );
+ gtk_object_set_data( GTK_OBJECT( FileSelector ),"FileSelector",FileSelector );
+ gtk_widget_set_usize( FileSelector,512,300 );
+ GTK_WIDGET_SET_FLAGS( FileSelector,GTK_CAN_DEFAULT );
+ gtk_widget_set_events( FileSelector,GDK_EXPOSURE_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK | GDK_KEY_PRESS_MASK | GDK_KEY_RELEASE_MASK | GDK_FOCUS_CHANGE_MASK | GDK_STRUCTURE_MASK | GDK_PROPERTY_CHANGE_MASK | GDK_VISIBILITY_NOTIFY_MASK );
+ gtk_window_set_title( GTK_WINDOW( FileSelector ),MSGTR_FileSelect );
+ gtk_window_set_position( GTK_WINDOW( FileSelector ),GTK_WIN_POS_CENTER );
+ gtk_window_set_policy( GTK_WINDOW( FileSelector ),TRUE,TRUE,TRUE );
+ gtk_window_set_wmclass( GTK_WINDOW( FileSelector ),"FileSelect","MPlayer" );
  fsColorMap=gdk_colormap_get_system();
 
- gtk_widget_realize( fsFileSelect );
- gtkAddIcon( fsFileSelect );
+ gtk_widget_realize( FileSelector );
+ gtkAddIcon( FileSelector );
 
- style=gtk_widget_get_style( fsFileSelect );
- dpixmap=gdk_pixmap_colormap_create_from_xpm_d( fsFileSelect->window,fsColorMap,&dmask,&style->bg[GTK_STATE_NORMAL],(gchar **)dir_xpm );
- fpixmap=gdk_pixmap_colormap_create_from_xpm_d( fsFileSelect->window,fsColorMap,&fmask,&style->bg[GTK_STATE_NORMAL],(gchar **)file_xpm );
+ style=gtk_widget_get_style( FileSelector );
+ dpixmap=gdk_pixmap_colormap_create_from_xpm_d( FileSelector->window,fsColorMap,&dmask,&style->bg[GTK_STATE_NORMAL],(gchar **)dir_xpm );
+ fpixmap=gdk_pixmap_colormap_create_from_xpm_d( FileSelector->window,fsColorMap,&fmask,&style->bg[GTK_STATE_NORMAL],(gchar **)file_xpm );
 
- vbox4=AddVBox( AddDialogFrame( fsFileSelect ),0 );
+ vbox4=AddVBox( AddDialogFrame( FileSelector ),0 );
  hbox4=AddHBox( vbox4,1 );
 
  fsCombo4=gtk_combo_new();
@@ -577,8 +577,8 @@
  gtk_box_pack_start( GTK_BOX( hbox4 ),vseparator1,FALSE,TRUE,0 );
  gtk_widget_set_usize( vseparator1,7,20 );
 
- upstyle=gtk_widget_get_style( fsFileSelect );
- uppixmap=gdk_pixmap_colormap_create_from_xpm_d( fsFileSelect->window,fsColorMap,&upmask,&upstyle->bg[GTK_STATE_NORMAL],(gchar **)up_xpm );
+ upstyle=gtk_widget_get_style( FileSelector );
+ uppixmap=gdk_pixmap_colormap_create_from_xpm_d( FileSelector->window,fsColorMap,&upmask,&upstyle->bg[GTK_STATE_NORMAL],(gchar **)up_xpm );
  uppixmapwid=gtk_pixmap_new( uppixmap,upmask );
  gtk_widget_show( uppixmapwid );
 
@@ -613,7 +613,7 @@
  List=gtk_combo_new();
  gtk_widget_set_name( List,"List" );
  gtk_widget_ref( List );
- gtk_object_set_data_full( GTK_OBJECT( fsFileSelect ),"List",List,(GtkDestroyNotify)gtk_widget_unref );
+ gtk_object_set_data_full( GTK_OBJECT( FileSelector ),"List",List,(GtkDestroyNotify)gtk_widget_unref );
  gtk_widget_show( List );
  gtk_box_pack_start( GTK_BOX( vbox4 ),List,FALSE,FALSE,0 );
  gtk_widget_set_usize( List,-2,20 );
@@ -633,8 +633,8 @@
  fsOk=AddButton( MSGTR_Ok,hbuttonbox3 );
  fsCancel=AddButton( MSGTR_Cancel,hbuttonbox3 );
 
- gtk_signal_connect( GTK_OBJECT( fsFileSelect ),"destroy",GTK_SIGNAL_FUNC( fs_Destroy ), NULL );
- gtk_signal_connect( GTK_OBJECT( fsFileSelect ),"key_release_event",GTK_SIGNAL_FUNC( on_FileSelect_key_release_event ),NULL );
+ gtk_signal_connect( GTK_OBJECT( FileSelector ),"destroy",GTK_SIGNAL_FUNC( fs_Destroy ), NULL );
+ gtk_signal_connect( GTK_OBJECT( FileSelector ),"key_release_event",GTK_SIGNAL_FUNC( on_FileSelect_key_release_event ),NULL );
 
  gtk_signal_connect( GTK_OBJECT( fsFilterCombo ),"changed",GTK_SIGNAL_FUNC( fs_fsFilterCombo_changed ),fsFilterCombo );
  gtk_signal_connect( GTK_OBJECT( fsFilterCombo ),"activate",GTK_SIGNAL_FUNC( fs_fsFilterCombo_activate ),fsFilterCombo );
@@ -649,7 +649,7 @@
  gtk_signal_connect( GTK_OBJECT( fsFNameList ),"select_row",(GtkSignalFunc)fs_fsFNameList_select_row,NULL );
  gtk_signal_connect( GTK_OBJECT( fsFNameList ),"event", (GtkSignalFunc)fs_fsFNameList_event,NULL );
 
- return fsFileSelect;
+ return FileSelector;
 }
 
 void ShowFileSelect( int type,int modal )
@@ -659,14 +659,14 @@
  const gchar *fname;
  struct stat f;
 
- if ( fsFileSelect ) gtkActive( fsFileSelect );
-  else fsFileSelect=create_FileSelect();
+ if ( FileSelector ) gtkActive( FileSelector );
+  else FileSelector=create_FileSelect();
 
  fsType=type;
  switch ( type )
   {
    case FILESELECT_VIDEO_AUDIO:
-        gtk_window_set_title( GTK_WINDOW( fsFileSelect ),MSGTR_FileSelect );
+        gtk_window_set_title( GTK_WINDOW( FileSelector ),MSGTR_FileSelect );
         fsList_items=NULL;
         for( i=0;fsVideoFilterNames[i][0];i++ )
           fsList_items=g_list_append( fsList_items,fsVideoFilterNames[i][0] );
@@ -677,7 +677,7 @@
 	//tmp=guiInfo.Filename;
         break;
    case FILESELECT_SUBTITLE:
-        gtk_window_set_title( GTK_WINDOW( fsFileSelect ),MSGTR_SubtitleSelect );
+        gtk_window_set_title( GTK_WINDOW( FileSelector ),MSGTR_SubtitleSelect );
         fsList_items=NULL;
         for( i=0;fsSubtitleFilterNames[i][0];i++ )
           fsList_items=g_list_append( fsList_items,fsSubtitleFilterNames[i][0] );
@@ -688,7 +688,7 @@
 	tmp=guiInfo.SubtitleFilename;
         break;
 /*   case fsOtherSelector:
-        gtk_window_set_title( GTK_WINDOW( fsFileSelect ),MSGTR_OtherSelect );
+        gtk_window_set_title( GTK_WINDOW( FileSelector ),MSGTR_OtherSelect );
         fsList_items=NULL;
         for( i=0;fsOtherFilterNames[i][0];i++ )
           fsList_items=g_list_append( fsList_items,fsOtherFilterNames[i][0] );
@@ -698,7 +698,7 @@
 	tmp=guiInfo.Othername;
         break;*/
    case FILESELECT_AUDIO:
-	gtk_window_set_title( GTK_WINDOW( fsFileSelect ),MSGTR_AudioFileSelect );
+	gtk_window_set_title( GTK_WINDOW( FileSelector ),MSGTR_AudioFileSelect );
 	fsList_items=NULL;
 	for( i=0;fsAudioFileNames[i][0];i++ )
 	  fsList_items=g_list_append( fsList_items,fsAudioFileNames[i][0] );
@@ -709,7 +709,7 @@
 	tmp=guiInfo.AudioFilename;
 	break;
    case FILESELECT_FONT:
-        gtk_window_set_title( GTK_WINDOW( fsFileSelect ),MSGTR_FontSelect );
+        gtk_window_set_title( GTK_WINDOW( FileSelector ),MSGTR_FontSelect );
 	fsList_items=NULL;
 	for( i=0;fsFontFileNames[i][0];i++ )
 	  fsList_items=g_list_append( fsList_items,fsFontFileNames[i][0] );
@@ -769,7 +769,7 @@
  gtk_clist_select_row( GTK_CLIST( fsFNameList ),fsLastFNameListSelected,1 );
  fsLastFNameListSelected = 0;
 
- gtk_window_set_modal( GTK_WINDOW( fsFileSelect ),modal );
+ gtk_window_set_modal( GTK_WINDOW( FileSelector ),modal );
 
- gtk_widget_show( fsFileSelect );
+ gtk_widget_show( FileSelector );
 }
--- a/gui/dialog/fileselect.h	Thu Mar 28 16:23:39 2013 +0000
+++ b/gui/dialog/fileselect.h	Thu Mar 28 16:35:59 2013 +0000
@@ -29,7 +29,7 @@
     FILESELECT_FONT
 };
 
-extern GtkWidget *fsFileSelect;
+extern GtkWidget *FileSelector;
 
 void ShowFileSelect(int type, int modal);
 
--- a/gui/dialog/preferences.c	Thu Mar 28 16:23:39 2013 +0000
+++ b/gui/dialog/preferences.c	Thu Mar 28 16:35:59 2013 +0000
@@ -658,7 +658,7 @@
 #endif
    case bLFont:
         ShowFileSelect( FILESELECT_FONT,FALSE );
-	gtkSetLayer( fsFileSelect );
+	gtkSetLayer( FileSelector );
 	break;
   }
 }