[PATCH 1/2] divelist.c: Use the trip->expanded flag in entry_selection()
Lubomir I. Ivanov
neolit123 at gmail.com
Mon Feb 18 05:34:48 PST 2013
From: "Lubomir I. Ivanov" <neolit123 at gmail.com>
Attempt to use the trip->expanded flag instead of
gtk_tree_view_row_expanded(). Fixes an issue where if an expanded
trip is selected the number of dives inside are not reported correctly.
This change also makes sure that a profile of the first dive in a trip
is always drawn.
Signed-off-by: Lubomir I. Ivanov <neolit123 at gmail.com>
---
divelist.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/divelist.c b/divelist.c
index b5fe48e..7ffbb72 100644
--- a/divelist.c
+++ b/divelist.c
@@ -2745,7 +2745,7 @@ static void entry_selected(GtkTreeModel *model, GtkTreePath *path, GtkTreeIter *
return;
trip->selected = 1;
/* If this is expanded, let the gtk selection happen for each dive under it */
- if (gtk_tree_view_row_expanded(GTK_TREE_VIEW(dive_list.tree_view), path))
+ if (trip->expanded)
return;
/* Otherwise, consider each dive under it selected */
for_each_dive(i, dive) {
--
1.7.11.msysgit.0
More information about the subsurface
mailing list