Commit 66bcd520 authored by Federico Mena Quintero's avatar Federico Mena Quintero Committed by Federico Mena Quintero
Browse files

Expand the Save example to point out the correct usage of

2005-07-21  Federico Mena Quintero  <federico@ximian.com>

	* gtk/tmpl/gtkfilechooserdialog.sgml (dialog): Expand the Save
	example to point out the correct usage of _set_current_folder()
	and _set_current_name(), versus _set_filename() alone.
parent 49e9aef5
2005-07-21 Federico Mena Quintero <federico@ximian.com>
* gtk/tmpl/gtkfilechooserdialog.sgml (dialog): Expand the Save
example to point out the correct usage of _set_current_folder()
and _set_current_name(), versus _set_filename() alone.
2005-07-15 Matthias Clasen <mclasen@redhat.com>
* === Released 2.7.3 ===
......
......@@ -65,6 +65,15 @@ dialog = gtk_file_chooser_dialog_new ("Save File",
NULL);
gtk_file_chooser_set_do_overwrite_confirmation (GTK_FILE_CHOOSER (dialog), TRUE);
if (user_edited_a_new_document)
{
gtk_file_chooser_set_current_folder (GTK_FILE_CHOOSER (dialog), default_folder_for_saving);
gtk_file_chooser_set_current_name (GTK_FILE_CHOOSER (dialog), "Untitled document");
}
else
gtk_file_chooser_set_filename (GTK_FILE_CHOOSER (dialog), filename_for_existing_document);
if (gtk_dialog_run (GTK_DIALOG (dialog)) == GTK_RESPONSE_ACCEPT)
{
char *filename;
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment