Fixed restoration of the panel divider position.
[psensor.git] / src / ui_sensorpref.c
index 17bfbd7..b87d53d 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * Copyright (C) 2010-2014 jeanfi@gmail.com
+ * Copyright (C) 2010-2016 jeanfi@gmail.com
  *
  * This program is free software; you can redistribute it and/or
  * modify it under the terms of the GNU General Public License as
@@ -54,7 +54,8 @@ static GtkSpinButton *w_sensor_low_threshold;
 static GtkListStore *store;
 
 /* 'true' when the notifications of field changes are due to the change
- * of the selected sensor. */
+ * of the selected sensor.
+ */
 static bool ignore_changes;
 
 static struct psensor *get_selected_sensor(void)
@@ -466,6 +467,8 @@ static GtkBuilder *load_ui(struct ui_psensor *ui)
        store = GTK_LIST_STORE(gtk_builder_get_object(builder,
                                                      "sensors_liststore"));
 
+       gtk_window_set_transient_for(GTK_WINDOW(w_dialog),
+                                    GTK_WINDOW(ui->main_window));
        gtk_builder_connect_signals(builder, ui);
 
        g_signal_connect(w_dialog,