OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) |
3 * (C) 1999 Antti Koivisto (koivisto@kde.org) | 3 * (C) 1999 Antti Koivisto (koivisto@kde.org) |
4 * (C) 2001 Dirk Mueller (mueller@kde.org) | 4 * (C) 2001 Dirk Mueller (mueller@kde.org) |
5 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2013 Apple Inc. All rights
reserved. | 5 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2013 Apple Inc. All rights
reserved. |
6 * | 6 * |
7 * This library is free software; you can redistribute it and/or | 7 * This library is free software; you can redistribute it and/or |
8 * modify it under the terms of the GNU Library General Public | 8 * modify it under the terms of the GNU Library General Public |
9 * License as published by the Free Software Foundation; either | 9 * License as published by the Free Software Foundation; either |
10 * version 2 of the License, or (at your option) any later version. | 10 * version 2 of the License, or (at your option) any later version. |
(...skipping 857 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
868 { | 868 { |
869 Vector<RefPtr<Node>> result; | 869 Vector<RefPtr<Node>> result; |
870 for (Node* node = firstChild(); node; node = node->nextSibling()) | 870 for (Node* node = firstChild(); node; node = node->nextSibling()) |
871 result.append(node); | 871 result.append(node); |
872 return result; | 872 return result; |
873 } | 873 } |
874 | 874 |
875 Vector<RefPtr<Element>> ContainerNode::getChildElements() const | 875 Vector<RefPtr<Element>> ContainerNode::getChildElements() const |
876 { | 876 { |
877 Vector<RefPtr<Element>> result; | 877 Vector<RefPtr<Element>> result; |
878 for (Element* element = ElementTraversal::firstWithin(*this); element; eleme
nt = ElementTraversal::next(*element, this)) | 878 for (Element* element = ElementTraversal::firstChild(*this); element; elemen
t = ElementTraversal::nextSibling(*element)) |
879 result.append(element); | 879 result.append(element); |
880 return result; | 880 return result; |
881 } | 881 } |
882 | 882 |
883 void ContainerNode::append(Vector<RefPtr<Node>>& nodes, ExceptionState& es) | 883 void ContainerNode::append(Vector<RefPtr<Node>>& nodes, ExceptionState& es) |
884 { | 884 { |
885 RefPtr<ContainerNode> protect(this); | 885 RefPtr<ContainerNode> protect(this); |
886 for (auto& node : nodes) { | 886 for (auto& node : nodes) { |
887 appendChild(node.release(), es); | 887 appendChild(node.release(), es); |
888 if (es.had_exception()) | 888 if (es.had_exception()) |
(...skipping 109 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
998 return true; | 998 return true; |
999 | 999 |
1000 if (node->isElementNode() && toElement(node)->shadow()) | 1000 if (node->isElementNode() && toElement(node)->shadow()) |
1001 return true; | 1001 return true; |
1002 | 1002 |
1003 return false; | 1003 return false; |
1004 } | 1004 } |
1005 #endif | 1005 #endif |
1006 | 1006 |
1007 } // namespace blink | 1007 } // namespace blink |
OLD | NEW |