Code

allow easy access to templates profile dir from save dialog
authorbuliabyak <buliabyak@users.sourceforge.net>
Sun, 1 Apr 2007 01:18:40 +0000 (01:18 +0000)
committerbuliabyak <buliabyak@users.sourceforge.net>
Sun, 1 Apr 2007 01:18:40 +0000 (01:18 +0000)
src/file.cpp

index efbada33253b0717ed81bb011f85b58b06ffcdd8..0a81069d94f1e193cb8106c26b4a58cdade9d91b 100644 (file)
@@ -621,6 +621,11 @@ sp_file_save_dialog(SPDocument *doc, bool is_copy)
     saveDialog->change_title(dialog_title);
     saveDialog->setSelectionType(extension);
 
+    // allow easy access to the user's own templates folder             
+    gchar *templates = profile_path ("templates");
+    dynamic_cast<Gtk::FileChooser *>(saveDialog)->add_shortcut_folder(templates);
+    g_free (templates);
+
     bool success = saveDialog->show();
     if (!success) {
         delete saveDialog;