summaryrefslogtreecommitdiffstats
path: root/info-gtk.c
diff options
context:
space:
mode:
Diffstat (limited to 'info-gtk.c')
-rw-r--r--info-gtk.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/info-gtk.c b/info-gtk.c
index cb9d87b7b..8e9b9442a 100644
--- a/info-gtk.c
+++ b/info-gtk.c
@@ -777,8 +777,15 @@ int edit_multi_dive_info(struct dive *single_dive)
update_cylinder_related_info(master);
/* if there was only one dive we might also have changed dive->when
* or even the duration and depth information (in a dive without samples) */
- if (! multi)
+ if (! multi) {
update_time_depth(master, &edit_dive);
+ /* these values could have changed because of the edit - so let's
+ * recreate them */
+ master->duration.seconds = 0;
+ master->maxdepth.mm = 0;
+ master->meandepth.mm = 0;
+ (void)fixup_dive(master);
+ }
dive_list_update_dives();
}
gtk_widget_destroy(dialog);