changeset 35938:8515446e81c6

Cosmetic: Rename variables holding data in UTF-8 encoding.
author ib
date Thu, 21 Mar 2013 09:56:58 +0000
parents f5b0d03fbc3b
children 736092b4a1be
files gui/dialog/fileselect.c gui/dialog/playlist.c
diffstat 2 files changed, 12 insertions(+), 12 deletions(-) [+]
line wrap: on
line diff
--- a/gui/dialog/fileselect.c	Thu Mar 21 09:43:36 2013 +0000
+++ b/gui/dialog/fileselect.c	Thu Mar 21 09:56:58 2013 +0000
@@ -343,7 +343,7 @@
  if ( fsPathTable ) g_hash_table_destroy( fsPathTable ); fsPathTable=g_hash_table_new_full(g_str_hash, g_str_equal, free, free);
  {
   unsigned int  i, c = 1;
-  gchar *uname;
+  gchar *utf8name;
 
   if ( fsMedium )
    {
@@ -352,17 +352,17 @@
       {
        const gchar *fname;
        fname = cfg_old_filename_from_utf8(fsHistory[i]);
-       uname = g_filename_display_name(fname);
-       fsTopList_items=g_list_append( fsTopList_items,uname );
-       g_hash_table_insert(fsPathTable, strdup(uname), strdup(fname));
+       utf8name = g_filename_display_name(fname);
+       fsTopList_items=g_list_append( fsTopList_items,utf8name );
+       g_hash_table_insert(fsPathTable, strdup(utf8name), strdup(fname));
        if ( c ) c=gstrcmp( dir,fname );
       }
    }
   if ( c && dir )
    {
-     uname = g_filename_display_name( dir );
-     fsTopList_items=g_list_prepend( fsTopList_items,uname );
-     g_hash_table_insert(fsPathTable, strdup(uname), strdup(dir));
+     utf8name = g_filename_display_name( dir );
+     fsTopList_items=g_list_prepend( fsTopList_items,utf8name );
+     g_hash_table_insert(fsPathTable, strdup(utf8name), strdup(dir));
    }
  }
  free( dir );
--- a/gui/dialog/playlist.c	Thu Mar 21 09:43:36 2013 +0000
+++ b/gui/dialog/playlist.c	Thu Mar 21 09:56:58 2013 +0000
@@ -395,7 +395,7 @@
 {
  GtkCTreeNode  * node;
  DirNodeType   * DirNode;
- gchar 		   * text, * name = NULL;
+ gchar 		   * text, * utf8name = NULL;
  gchar 		   * dummy = "dummy";
  int     	 	 subdir = True;
  DIR   		   * dir = NULL;
@@ -419,14 +419,14 @@
        if ( !strcmp( current_path,"/" ) ) sprintf( path,"/%s",dirent->d_name );
 	else sprintf( path,"%s/%s",current_path,dirent->d_name );
        text=dirent->d_name;
-       g_free( name );
-       name=g_filename_display_name( text );
+       g_free( utf8name );
+       utf8name=g_filename_display_name( text );
 
        if ( stat( path,&statbuf ) != -1 && S_ISDIR( statbuf.st_mode ) && dirent->d_name[0] != '.' )
 	{
 	 DirNode=malloc( sizeof( DirNodeType ) ); DirNode->scaned=False; DirNode->path=strdup( path );
 	 subdir=check_for_subdir( path );
-	 node=gtk_ctree_insert_node( ctree,parent_node,NULL,&name,4,pxOpenedBook,msOpenedBook,pxClosedBook,msClosedBook,!subdir,FALSE );
+	 node=gtk_ctree_insert_node( ctree,parent_node,NULL,&utf8name,4,pxOpenedBook,msOpenedBook,pxClosedBook,msClosedBook,!subdir,FALSE );
 	 gtk_ctree_node_set_row_data_full( ctree,node,DirNode,NULL );
 	 if ( subdir ) gtk_ctree_insert_node( ctree,node,NULL,&dummy,4,NULL,NULL,NULL,NULL,FALSE,FALSE );
 	}
@@ -439,7 +439,7 @@
    gtk_clist_thaw( GTK_CLIST( ctree ) );
   }
 
-  g_free( name );
+  g_free( utf8name );
 }
 
 static void scan_dir( char * path )