From 5e7f439f6aef964eb335174ddcd55c5af107e35f Mon Sep 17 00:00:00 2001 From: Kaj-Michael Lang Date: Mon, 23 Jul 2007 15:36:10 +0300 Subject: [PATCH] Rename browse button name as it's not just pois anymore. --- src/settings-gui.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/src/settings-gui.c b/src/settings-gui.c index 8b207ff..3933351 100644 --- a/src/settings-gui.c +++ b/src/settings-gui.c @@ -38,6 +38,7 @@ gboolean settings_dialog_browse_forfile(GtkWidget * widget, BrowseInfo * browse_info) { GtkWidget *dialog; + gint res; printf("%s()\n", __PRETTY_FUNCTION__); dialog = @@ -51,7 +52,8 @@ settings_dialog_browse_forfile(GtkWidget * widget, BrowseInfo * browse_info) (browse_info-> txt))); - if (GTK_RESPONSE_OK == gtk_dialog_run(GTK_DIALOG(dialog))) { + res=gtk_dialog_run(GTK_DIALOG(dialog)); + if (res==GTK_RESPONSE_OK || res==GTK_RESPONSE_ACCEPT) { gchar *filename = gtk_file_chooser_get_filename(GTK_FILE_CHOOSER(dialog)); gtk_entry_set_text(GTK_ENTRY(browse_info->txt), filename); @@ -402,7 +404,7 @@ gboolean settings_dialog() GtkWidget *btn_colors; GtkWidget *txt_mapper_db; - GtkWidget *btn_browsepoi; + GtkWidget *btn_browsedb; GtkWidget *num_poi_zoom; GtkWidget *chk_speed_limit_on; GtkWidget *num_speed; @@ -691,7 +693,7 @@ gboolean settings_dialog() gtk_box_pack_start(GTK_BOX(hbox), txt_mapper_db = gtk_entry_new(), TRUE, TRUE, 0); gtk_box_pack_start(GTK_BOX(hbox), - btn_browsepoi = + btn_browsedb = gtk_button_new_with_label(_("Browse...")), FALSE, FALSE, 0); @@ -718,7 +720,7 @@ gboolean settings_dialog() browse_info.dialog = dialog; browse_info.txt = txt_mapper_db; - g_signal_connect(G_OBJECT(btn_browsepoi), "clicked", + g_signal_connect(G_OBJECT(btn_browsedb), "clicked", G_CALLBACK(settings_dialog_browse_forfile), &browse_info); -- 2.39.5