summaryrefslogtreecommitdiff
path: root/src/gui
diff options
context:
space:
mode:
Diffstat (limited to 'src/gui')
-rw-r--r--src/gui/menus/project.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/gui/menus/project.c b/src/gui/menus/project.c
index 7e9fc3f..96b411b 100644
--- a/src/gui/menus/project.c
+++ b/src/gui/menus/project.c
@@ -192,6 +192,14 @@ static void mcb_project_add_binary_file(GtkMenuItem *menuitem, GMenuBar *bar)
free(dir);
}
+ if (g_study_project_get_filename(get_current_project()) != NULL)
+ {
+ dir = strdup(g_study_project_get_filename(get_current_project()));
+ dir = dirname(dir);
+ gtk_file_chooser_set_current_folder(GTK_FILE_CHOOSER(dialog), dir);
+ free(dir);
+ }
+
if (gtk_dialog_run(GTK_DIALOG(dialog)) == GTK_RESPONSE_ACCEPT)
{
filename = gtk_file_chooser_get_filename(GTK_FILE_CHOOSER(dialog));