mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
Undo: implement undo of manual dive-creation
Play manual addition of dives via an UndoCommand. Since this does in large parts the same thing as undo/redo of dive deletion (just the other way round and only a single instead of multiple dive), factor out the functions that add/delete dives and take care of trips. The UI-interaction is just mindless copy&paste and will have to be adapted. Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
This commit is contained in:
parent
61467ea0d5
commit
12df9faaa2
7 changed files with 1064 additions and 64 deletions
|
|
@ -42,6 +42,7 @@ extern void find_new_trip_start_time(dive_trip_t *trip);
|
|||
extern struct dive *first_selected_dive();
|
||||
extern struct dive *last_selected_dive();
|
||||
extern bool is_trip_before_after(const struct dive *dive, bool before);
|
||||
extern int get_dive_nr_at_idx(int idx);
|
||||
extern void set_dive_nr_for_current_dive();
|
||||
extern timestamp_t get_surface_interval(timestamp_t when);
|
||||
extern void delete_dive_from_table(struct dive_table *table, int idx);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue