changeset 14960:91d8fb14bd27

[gaim-migrate @ 17739] The doc tells to use _set_current_name instead of set_filename for new files. This fixes the bug reported by TheNux in #gaim. committer: Tailor Script <tailor@pidgin.im>
author Sadrul Habib Chowdhury <imadil@gmail.com>
date Sat, 11 Nov 2006 23:35:07 +0000
parents 0c80979077cf
children 8a564904e9b5
files gtk/gtkrequest.c
diffstat 1 files changed, 6 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/gtk/gtkrequest.c	Sat Nov 11 20:29:35 2006 +0000
+++ b/gtk/gtkrequest.c	Sat Nov 11 23:35:07 2006 +0000
@@ -1527,8 +1527,12 @@
 		current_folder = gaim_prefs_get_string("/gaim/gtk/filelocations/last_open_folder");
 	}
 
-	if (filename != NULL)
-		gtk_file_chooser_set_filename(GTK_FILE_CHOOSER(filesel), filename);
+	if (filename != NULL) {
+		if (savedialog)
+			gtk_file_chooser_set_current_name(GTK_FILE_CHOOSER(filesel), filename);
+		else
+			gtk_file_chooser_set_filename(GTK_FILE_CHOOSER(filesel), filename);
+	}
 	if ((current_folder != NULL) && (*current_folder != '\0')) {
 		folder_set = gtk_file_chooser_set_current_folder(GTK_FILE_CHOOSER(filesel), current_folder);
 	}