mirror of
https://github.com/subsurface/subsurface.git
synced 2024-11-30 22:20:21 +00:00
Clear yearly statistics when closing data file
Another oversight of what needed to be done when cleaning up the UI after closing the data file. Reported-by: Sergey Starosek <sergey.starosek@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
0f2fac265f
commit
b709dff23d
2 changed files with 3 additions and 1 deletions
|
@ -249,6 +249,7 @@ static void file_close(GtkWidget *w, gpointer data)
|
|||
process_selected_dives();
|
||||
clear_stats_widgets();
|
||||
clear_events();
|
||||
show_dive_stats(NULL);
|
||||
|
||||
/* clear the equipment page */
|
||||
clear_equipment_widgets();
|
||||
|
|
|
@ -543,7 +543,8 @@ static void show_single_dive_stats(struct dive *dive)
|
|||
struct tm tm;
|
||||
|
||||
process_all_dives(dive, &prev_dive);
|
||||
|
||||
if (!dive)
|
||||
return;
|
||||
utc_mkdate(dive->when, &tm);
|
||||
snprintf(buf, sizeof(buf),
|
||||
/*++GETTEXT 80 chars: weekday, monthname, day, year, hour, min */
|
||||
|
|
Loading…
Reference in a new issue