]> git.tdb.fi Git - ext/subsurface.git/commitdiff
Improve group selection semantics
authorLinus Torvalds <torvalds@linux-foundation.org>
Mon, 20 Aug 2012 13:45:56 +0000 (06:45 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Mon, 20 Aug 2012 13:45:56 +0000 (06:45 -0700)
Now that the last commit tried to avoid changing the child selections if
the selected group partially matched, we should always [un]select all
children when we actually decide to change something.

Before, it would try to minimize selection damage by stopping
[un]selecting when it hit a child that already matched the selection,
but since we minimize damage differently, the all-or-nothing approach is
better, and gets us sane behavior when the group is collapsed.

Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
divelist.c

index 13db0a5fd29bb839577864fbd4a9507294af2588..ef34b065c667ccd2f0fd4b533310c2ba50273888 100644 (file)
@@ -226,7 +226,7 @@ static void select_dive_group(GtkTreeModel *model, GtkTreeSelection *selection,
                first = 0;
                dive = get_dive(idx);
                if (dive->selected == selected)
-                       break;
+                       continue;
 
                select_dive(dive, selected);
                if (selected)