Fixed restoration of the panel divider position.
[psensor.git] / src / ui_sensorlist.c
index f9b5fba..9d4b748 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
@@ -110,7 +110,10 @@ void ui_sensorlist_update(struct ui_psensor *ui, bool complete)
 
        store = ui->sensors_store;
 
-       use_celsius = ui->config->temperature_unit == CELSIUS;
+       if (config_get_temperature_unit() == CELSIUS)
+               use_celsius = 1;
+       else
+               use_celsius = 0;
 
        valid = gtk_tree_model_get_iter_first(model, &iter);
        while (valid) {