aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorScott Tepavich2012-05-31 20:36:47 (EDT)
committerEugene Tarassov2012-06-01 19:47:11 (EDT)
commitd60d2085bc3eafc37f0d943ce0758bc711a6bea6 (patch)
tree91193bb776df4a3ccaac3d270683c8b3efc86f06
parent42c9fbbe8b819544e1beeaca4581f13545e17370 (diff)
downloadorg.eclipse.tcf-d60d2085bc3eafc37f0d943ce0758bc711a6bea6.zip
org.eclipse.tcf-d60d2085bc3eafc37f0d943ce0758bc711a6bea6.tar.gz
org.eclipse.tcf-d60d2085bc3eafc37f0d943ce0758bc711a6bea6.tar.bz2
Bug [381103] Context tree control collapsed and odd context selection.
-rw-r--r--plugins/org.eclipse.tcf.cdt.ui/src/org/eclipse/tcf/internal/cdt/ui/breakpoints/TCFThreadFilterEditor.java15
1 files changed, 6 insertions, 9 deletions
diff --git a/plugins/org.eclipse.tcf.cdt.ui/src/org/eclipse/tcf/internal/cdt/ui/breakpoints/TCFThreadFilterEditor.java b/plugins/org.eclipse.tcf.cdt.ui/src/org/eclipse/tcf/internal/cdt/ui/breakpoints/TCFThreadFilterEditor.java
index 1909a34..72ca9aa 100644
--- a/plugins/org.eclipse.tcf.cdt.ui/src/org/eclipse/tcf/internal/cdt/ui/breakpoints/TCFThreadFilterEditor.java
+++ b/plugins/org.eclipse.tcf.cdt.ui/src/org/eclipse/tcf/internal/cdt/ui/breakpoints/TCFThreadFilterEditor.java
@@ -210,15 +210,12 @@ public class TCFThreadFilterEditor {
filteredList.add(obj);
break;
}
- }
- // Some queries eliminate parent elements for grandchild matches.
- if (filteredList.size() == 0) {
- for (Object check_obj : resultArray) {
- if ( check_obj instanceof Context && ((Context)obj).fIsContainer) {
- Object[] childArray = getChildren(check_obj);
- if (childArray != null) {
- filteredList.addAll(Arrays.asList(childArray));
- }
+ else if (obj instanceof Context && ((Context)obj).fIsContainer) {
+ // Some filters skip a generation. Check children before passing.
+ Object[] childArray = getChildren(obj);
+ if (childArray != null && childArray.length != 0) {
+ filteredList.add(obj);
+ break;
}
}
}