diff options
author | Berthold Stoeger <bstoeger@mail.tuwien.ac.at> | 2020-02-23 11:05:19 +0100 |
---|---|---|
committer | Berthold Stoeger <bstoeger@mail.tuwien.ac.at> | 2020-04-07 00:13:34 +0200 |
commit | 2453d4fc1fa6c6109645853483839f1e3c87d4a8 (patch) | |
tree | c5555dfe98f91beed0cb99291b31e34ddb88c26c /core/equipment.h | |
parent | 64a5f10cfe9bf82bcab3efc99961bd20cf602df9 (diff) | |
download | subsurface-2453d4fc1fa6c6109645853483839f1e3c87d4a8.tar.gz |
core: introduce clone_cylinder() function
We have a clone_weightsystem function. For symmetry, introduce
a clone_cylinder() function so that we can more-or-less copy&paste
the weightsystem undo code for cylinder undo.
Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
Diffstat (limited to 'core/equipment.h')
-rw-r--r-- | core/equipment.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/core/equipment.h b/core/equipment.h index b62587447..74f04dfdf 100644 --- a/core/equipment.h +++ b/core/equipment.h @@ -75,6 +75,7 @@ extern weightsystem_t clone_weightsystem(weightsystem_t ws); extern void free_weightsystem(weightsystem_t ws); extern void copy_cylinder_types(const struct dive *s, struct dive *d); extern void add_cloned_weightsystem(struct weightsystem_table *t, weightsystem_t ws); +extern cylinder_t clone_cylinder(cylinder_t cyl); extern cylinder_t *add_empty_cylinder(struct cylinder_table *t); extern void add_cloned_cylinder(struct cylinder_table *t, cylinder_t cyl); extern cylinder_t *get_cylinder(const struct dive *d, int idx); |