Round the maximum depth on dive list

Round maximum depth on dive list to get consistent data between the dive
list and dive info.

Signed-off-by: Miika Turkia <miika.turkia@gmail.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
This commit is contained in:
Miika Turkia 2011-12-09 18:56:34 +02:00 committed by Linus Torvalds
parent 9b1ea2ae6d
commit 6131dbc74c

View file

@ -160,8 +160,9 @@ static void depth_data_func(GtkTreeViewColumn *col,
frac = depth % 10;
if (integer < 20)
break;
if (frac >= 5)
integer++;
frac = -1;
/* Rounding? */
break;
case FEET:
integer = mm_to_feet(depth) + 0.5;