summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar Linus Torvalds <torvalds@linux-foundation.org>2012-09-11 00:57:15 +0800
committerGravatar Linus Torvalds <torvalds@linux-foundation.org>2012-09-11 00:57:15 +0800
commit3febfb74fa092b12b7f0a3e8d05b11b6ab6da397 (patch)
treedbac0910ae34857b74daa910a143606535cec7eb
parentf51066fe40cb8d0bf9b6130adc1c85af3934ffe7 (diff)
parent109dab56eb32bca4d43ada6b62f5c29e5e10b687 (diff)
downloadsubsurface-3febfb74fa092b12b7f0a3e8d05b11b6ab6da397.tar.gz
Merge branch 'ui-work' of git://git.hohndel.org/subsurface
Pull small UI updates from Dirk Hohndel: "Not sure if you like the change to the About screen. :-) The other one is simply a small improvement for people importing xml files from the UI - it gets them an at least somewhat sane starting directory to work from." * 'ui-work' of git://git.hohndel.org/subsurface: Set default path for file import to the last path opened Update the About screen
-rw-r--r--gtk-gui.c10
1 files changed, 7 insertions, 3 deletions
diff --git a/gtk-gui.c b/gtk-gui.c
index a2f130ac2..79933fb85 100644
--- a/gtk-gui.c
+++ b/gtk-gui.c
@@ -697,10 +697,10 @@ static void about_dialog(GtkWidget *w, gpointer data)
gtk_show_about_dialog(NULL,
"program-name", "SubSurface",
- "comments", "Half-arsed divelog software in C",
+ "comments", "Multi-platform divelog software in C",
"license", "GPLv2",
"version", VERSION_STRING,
- "copyright", "Linus Torvalds 2011",
+ "copyright", "Linus Torvalds, Dirk Hohndel, and others, 2011, 2012",
"logo-icon-name", "subsurface",
/* Must be last: */
logo_property, logo,
@@ -1174,6 +1174,7 @@ static GtkWidget *xml_file_selector(GtkWidget *vbox, GtkWidget *main_dialog)
{
GtkWidget *hbox, *frame, *chooser, *dialog;
GtkFileFilter *filter;
+ char *current_file, *current_dir;
hbox = gtk_hbox_new(FALSE, 6);
gtk_box_pack_start(GTK_BOX(vbox), hbox, FALSE, FALSE, 3);
@@ -1187,7 +1188,10 @@ static GtkWidget *xml_file_selector(GtkWidget *vbox, GtkWidget *main_dialog)
GTK_STOCK_OPEN, GTK_RESPONSE_ACCEPT,
NULL);
gtk_file_chooser_set_select_multiple(GTK_FILE_CHOOSER(dialog), FALSE);
-
+ current_dir = path_and_file(existing_filename, &current_file);
+ gtk_file_chooser_set_current_folder(GTK_FILE_CHOOSER(dialog), current_dir);
+ free(current_dir);
+ free(current_file);
filter = gtk_file_filter_new();
gtk_file_filter_add_pattern(filter, "*.xml");
gtk_file_filter_add_pattern(filter, "*.XML");