mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-07 19:43:24 +00:00
Clear the display widgets when deleting all dives in the list
After calling dive_list_update_dives() in delete_selected_dives_cb(), if the selection length is zero, we can clear the display widgets not to show information of a deleted dive. [Dirk Hohndel: please watch your whitespace - you once again added a bunch of empty lines that really didn't help the code... I removed them] Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
69aec317f0
commit
3e3e632e1f
1 changed files with 9 additions and 0 deletions
|
@ -1934,6 +1934,15 @@ static void delete_selected_dives_cb(GtkWidget *menuitem, GtkTreePath *path)
|
||||||
}
|
}
|
||||||
dive_list_update_dives();
|
dive_list_update_dives();
|
||||||
restore_tree_state();
|
restore_tree_state();
|
||||||
|
|
||||||
|
/* if no dives are selected at this point clear the display widgets */
|
||||||
|
if (!amount_selected) {
|
||||||
|
selected_dive = 0;
|
||||||
|
process_selected_dives();
|
||||||
|
clear_stats_widgets();
|
||||||
|
clear_equipment_widgets();
|
||||||
|
show_dive_info(NULL);
|
||||||
|
}
|
||||||
mark_divelist_changed(TRUE);
|
mark_divelist_changed(TRUE);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue