X-Git-Url: https://git.wpitchoune.net/gitweb/?p=psensor.git;a=blobdiff_plain;f=src%2Fui_sensorpref.c;h=17bfbd70169ccc5051d9d8fee1dcb9e222e45c76;hp=ffede58aba59f904fcd3fd9764264b50f6a9c98a;hb=270d8e258b541a4e481c7323a2c1feb49f19dc2e;hpb=88bdf7fed0d4f2c891cf6aedebe230a03a1eaf20 diff --git a/src/ui_sensorpref.c b/src/ui_sensorpref.c index ffede58..17bfbd7 100644 --- a/src/ui_sensorpref.c +++ b/src/ui_sensorpref.c @@ -235,7 +235,7 @@ ui_sensorpref_alarm_high_threshold_changed_cb(GtkSpinButton *btn, gpointer data) return; v = gtk_spin_button_get_value(btn); - if (config_get_sensor_unit() == FAHRENHEIT) + if (config_get_temperature_unit() == FAHRENHEIT) v = fahrenheit_to_celsius(v); config_set_sensor_alarm_high_threshold(s->id, v); @@ -258,7 +258,7 @@ ui_sensorpref_alarm_low_threshold_changed_cb(GtkSpinButton *btn, gpointer data) return; v = gtk_spin_button_get_value(btn); - if (config_get_sensor_unit() == FAHRENHEIT) + if (config_get_temperature_unit() == FAHRENHEIT) v = fahrenheit_to_celsius(v); config_set_sensor_alarm_low_threshold(s->id, v); @@ -289,7 +289,7 @@ static void update_pref(struct psensor *s) chip = _("Unknown"); gtk_label_set_text(w_sensor_chipname, chip); - use_celsius = config_get_sensor_unit() == CELSIUS ? 1 : 0; + use_celsius = config_get_temperature_unit() == CELSIUS ? 1 : 0; if (s->min == UNKNOWN_DBL_VALUE) smin = strdup(_("Unknown"));