Use renderer function for divelist depth field too

Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
This commit is contained in:
Linus Torvalds 2011-09-19 18:52:23 -07:00
parent fa2a6fb763
commit 2a45f6dbc3
2 changed files with 24 additions and 22 deletions

7
dive.h
View file

@ -86,9 +86,14 @@ typedef struct {
pressure_t start, end;
} cylinder_t;
static inline double mm_to_feet(int mm)
{
return mm * 0.00328084;
}
static inline int to_feet(depth_t depth)
{
return depth.mm * 0.00328084 + 0.5;
return mm_to_feet(depth.mm) + 0.5;
}
static double mkelvin_to_C(int mkelvin)