Define O2 permille for air in one spot

Having the O2 permille defined once is more readable.

Signed-off-by: Henrik Brautaset Aronsen <subsurface@henrik.synth.no>
This commit is contained in:
Henrik Brautaset Aronsen 2011-12-31 17:15:59 +01:00
parent 2175226580
commit 16b6df559f
5 changed files with 8 additions and 6 deletions

View file

@ -285,7 +285,7 @@ static void show_cylinder(cylinder_t *cyl, struct cylinder_widget *cylinder)
o2 = cyl->gasmix.o2.permille / 10.0;
he = cyl->gasmix.he.permille / 10.0;
if (!o2)
o2 = 21.0;
o2 = AIR_PERMILLE / 10.0;
gtk_spin_button_set_value(GTK_SPIN_BUTTON(cylinder->o2), o2);
gtk_spin_button_set_value(GTK_SPIN_BUTTON(cylinder->he), he);
}