Bug fix: Start-up directory setting not preserved
[geeqie.git] / src / layout.c
index dc9352a..fe9a31e 100644 (file)
@@ -2108,18 +2108,30 @@ static void home_path_set_current_cb(GtkWidget *widget, gpointer data)
 static void startup_path_set_current_cb(GtkWidget *widget, gpointer data)
 {
        LayoutConfig *lc = data;
+       if (!gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON(widget)))
+               {
+               return;
+               }
        lc->options.startup_path = STARTUP_PATH_CURRENT;
 }
 
 static void startup_path_set_last_cb(GtkWidget *widget, gpointer data)
 {
        LayoutConfig *lc = data;
+       if (!gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON(widget)))
+               {
+               return;
+               }
        lc->options.startup_path = STARTUP_PATH_LAST;
 }
 
 static void startup_path_set_home_cb(GtkWidget *widget, gpointer data)
 {
        LayoutConfig *lc = data;
+       if (!gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON(widget)))
+               {
+               return;
+               }
        lc->options.startup_path = STARTUP_PATH_HOME;
 }