Community
Participate
Working Groups
in order to make the graying and checking work correctly, you need methods that are missing from CheckBoxTreeViewer API for that class is _very_ inconsistent: 1. there's setGrayChecked but it takes only 1 flag instead of 2 2. there's setParentsGrayed but there's no setParentsChecked 3. there's setSubtreeChecked but there's no setSubtreeGrayed is there any reason why these method should be missing? how do i work around this limitation?
1. setGrayChecked is just an optimization to set the gray and check state at the same time, to the same value. Use setGrayed and setChecked separately if this is not what you want. 2. When all child elements become white checked, you want to white check the parent, but not necessarily all parents, since there may be siblings that aren't white checked. What is your use case for wanting setParentsChecked? 3. Normally graying only occurs on parents, when not all children are checked. What is your use case here? Check box trees should maintain the following invariants: - parent is white checked IFF all children are white checked - parent is gray checked IFF some but not all children are unchecked or gray checked - parent is unchecked IFF all children are unchecked The viewer could do more to help with this, but it's not clear that the changes proposed above would actually help.
1. this method should be removed then - the performance benefit is next to none and confusion is real. no benefit in keeping such a method. 2. i select a leaf node - i want all parents checked 3. i select a middle-tier node - want all subnodes white (checked) >- parent is white checked IFF all children are white checked >- parent is gray checked IFF some but not all children are unchecked or gray >checked >- parent is unchecked IFF all children are unchecked btw, import wizard in the resource perspective violates *all* 3 of these rules. to make it work for our own dialogs we had to subclass the viewer and put workarounds for the missing functionality. i'm not saying these methods will be enough - but they are needed
Not for 2.1.
Not for 3.0.
Hitesh is now responsible for watching bugs in the [Viewers] component area.
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet. If you have further information on the current state of the bug, please add it. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant.