summaryrefslogtreecommitdiffstats
path: root/divelist-gtk.c
diff options
context:
space:
mode:
authorGravatar Tomaz Canabrava <tcanabrava@kde.org>2013-05-16 15:42:20 -0300
committerGravatar Tomaz Canabrava <tcanabrava@kde.org>2013-05-16 15:42:20 -0300
commit30297ebd4bbe9d3048e7c4401b3b4b22c24305e0 (patch)
treeb34cba0f93ce51829c714020a4363b3076bdd6ed /divelist-gtk.c
parenta55a2e5d88c2e822f64e36b96910632b37ba8d6d (diff)
downloadsubsurface-30297ebd4bbe9d3048e7c4401b3b4b22c24305e0.tar.gz
Correctly set the unselected dive.
The selected dive was being set to zero when the program started, but zero is actually the first dive. There were workarounds on the gtk code for that probably Signed-off-by: Tomaz Canabrava <tcanabrava@kde.org>
Diffstat (limited to 'divelist-gtk.c')
-rw-r--r--divelist-gtk.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/divelist-gtk.c b/divelist-gtk.c
index 0c26430c1..fc90cdf26 100644
--- a/divelist-gtk.c
+++ b/divelist-gtk.c
@@ -1268,7 +1268,7 @@ static void delete_selected_dives_cb(GtkWidget *menuitem, GtkTreePath *path)
/* if no dives are selected at this point clear the display widgets */
if (!amount_selected) {
- selected_dive = 0;
+ selected_dive = -1;
process_selected_dives();
clear_stats_widgets();
clear_equipment_widgets();