Show average max depth in yearly statistics

this was requested in #1854 and I think this suggestion makes sense

Fixes #1854

Signed-off-by: Robert C. Helling <helling@atdotde.de>
This commit is contained in:
Robert C. Helling 2018-12-16 20:52:34 +01:00 committed by bstoeger
parent 99561484ad
commit ac8db01873
5 changed files with 12 additions and 0 deletions

View file

@ -53,6 +53,7 @@ static void process_dive(struct dive *dive, stats_t *stats)
stats->max_depth.mm = dive->maxdepth.mm;
if (stats->min_depth.mm == 0 || dive->maxdepth.mm < stats->min_depth.mm)
stats->min_depth.mm = dive->maxdepth.mm;
stats->combined_max_depth.mm += dive->maxdepth.mm;
process_temperatures(dive, stats);