Browse Source

* TDOMNodeList.GetCount speed up from alexx, fixes #6891

git-svn-id: trunk@3568 -
florian 19 years ago
parent
commit
1e3352a350
1 changed files with 5 additions and 0 deletions
  1. 5 0
      fcl/xml/dom.pp

+ 5 - 0
fcl/xml/dom.pp

@@ -959,6 +959,11 @@ function TDOMNodeList.GetCount: LongWord;
 var
 var
   child: TDOMNode;
   child: TDOMNode;
 begin
 begin
+  if not UseFilter then
+    begin
+      Result := Count;
+      exit;
+    end;
   Result := 0;
   Result := 0;
   child := node.FirstChild;
   child := node.FirstChild;
   while Assigned(child) do
   while Assigned(child) do