Use Tree.CheckState[Node], not Node.CheckState to fix a potential OnCheck event. Fixes issue #2738.

This commit is contained in:
Ansgar Becker
2012-02-24 20:14:11 +00:00
parent 5baf38e7c3
commit b76bd09d13

View File

@ -1524,9 +1524,9 @@ begin
ObjNode.CheckState := csUncheckedNormal
else begin
if (WantedType = lntNone) or (DBObj.NodeType = WantedType) then
ObjNode.CheckState := csCheckedNormal
TreeObjects.CheckState[ObjNode] := csCheckedNormal
else
ObjNode.CheckState := csUncheckedNormal;
TreeObjects.CheckState[ObjNode] := csUncheckedNormal;
end;
if ObjNode.CheckState = csCheckedNormal then
Inc(CheckedNodes);