diff options
author | Graeme Geldenhuys <graeme@mastermaths.co.za> | 2011-10-27 16:50:34 +0200 |
---|---|---|
committer | Graeme Geldenhuys <graeme@mastermaths.co.za> | 2011-10-27 16:50:34 +0200 |
commit | d2695ee087ef57be43207bc34c5c2dcd7df4fd18 (patch) | |
tree | 3cab3cf4cd0bb9e655dbc9004ffc49c63ee0614e /src | |
parent | 8bfb96ab9fcc6e406f15e73c51ad682b34ba36a7 (diff) | |
download | fpGUI-d2695ee087ef57be43207bc34c5c2dcd7df4fd18.tar.xz |
tree: Added a note about the limitation of Node.HasChildren call.
For now, please use Node.Count instead.
Diffstat (limited to 'src')
-rw-r--r-- | src/gui/fpg_tree.pas | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/gui/fpg_tree.pas b/src/gui/fpg_tree.pas index 83ddddbb..578cc133 100644 --- a/src/gui/fpg_tree.pas +++ b/src/gui/fpg_tree.pas @@ -28,6 +28,9 @@ unit fpg_tree; we want a main column covering the tree. Then extra columns for user text and data. * Implement event handlers the user can hook into and do custom drawing. + * TfpgTreeNode.HasChildren property is not fully implemented yet. The + property is not update when you do .Append() or .AppendText() calls. It + such cases .Count is prefered. } {.$Define Debug} @@ -455,6 +458,7 @@ begin FLastSubNode.Next := ANode; FLastSubNode := ANode; + FHasChildren := True; end; function TfpgTreeNode.FindSubNode(AText: string; ARecursive: Boolean): TfpgTreeNode; @@ -756,6 +760,7 @@ begin Remove(tn); tn.Free; end; + FHasChildren := False; end; function TfpgTreeNode.ParentTextColor: TfpgColor; |