summaryrefslogtreecommitdiffstats
path: root/core/dive.h
diff options
context:
space:
mode:
authorGravatar Willem Ferguson <willemferguson@zoology.up.ac.za>2018-04-07 17:52:16 +0200
committerGravatar Lubomir I. Ivanov <neolit123@gmail.com>2018-05-14 23:47:00 +0300
commitcad4eb39c4ac0a46dbaab6932e9319704eb90e6d (patch)
treec9b1ff2298a5b4ec9684ee5b338f1e7110a66b12 /core/dive.h
parentb9174332d562b8b9c436a94880c51acf2c5ab761 (diff)
downloadsubsurface-cad4eb39c4ac0a46dbaab6932e9319704eb90e6d.tar.gz
Implement get_divemode() to find the divemode at a particular time
Replaced a rather cumbersome function that that did the above. Upon the suggestion of Robert Helling who proposed a much shorter way, this new function replaced the previous ones. This necessitated changes to divelist.c, profile.c and plannernotes.c, as well as dive.c/h. Signed-off-by: Willem Ferguson <willemferguson@zoology.up.ac.za>
Diffstat (limited to 'core/dive.h')
-rw-r--r--core/dive.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/core/dive.h b/core/dive.h
index d336318d5..75f042790 100644
--- a/core/dive.h
+++ b/core/dive.h
@@ -362,6 +362,7 @@ struct dive_components {
unsigned int weights : 1;
};
+extern enum dive_comp_type get_current_divemode(struct divecomputer *dc, int time, struct event **evp, enum dive_comp_type *divemode);
extern struct event *get_next_divemodechange(struct event **evd, bool update_pointer);
extern enum dive_comp_type get_divemode_at_time(struct divecomputer *dc, int dtime, struct event **ev_dmc);