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, 2010, 2011 Apple Inc. All r
ights reserved. | 5 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All r
ights reserved. |
6 * Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies) | 6 * Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies) |
7 * Copyright (C) 2009 Torch Mobile Inc. All rights reserved. (http://www.torchmo
bile.com/) | 7 * Copyright (C) 2009 Torch Mobile Inc. All rights reserved. (http://www.torchmo
bile.com/) |
8 * | 8 * |
9 * This library is free software; you can redistribute it and/or | 9 * This library is free software; you can redistribute it and/or |
10 * modify it under the terms of the GNU Library General Public | 10 * modify it under the terms of the GNU Library General Public |
(...skipping 1334 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1345 PassRefPtr<NodeList> Node::getElementsByName(const String& elementName) | 1345 PassRefPtr<NodeList> Node::getElementsByName(const String& elementName) |
1346 { | 1346 { |
1347 return ensureRareData().ensureNodeLists().addCacheWithAtomicName<NameNodeLis
t>(this, NameNodeListType, elementName); | 1347 return ensureRareData().ensureNodeLists().addCacheWithAtomicName<NameNodeLis
t>(this, NameNodeListType, elementName); |
1348 } | 1348 } |
1349 | 1349 |
1350 PassRefPtr<NodeList> Node::getElementsByClassName(const String& classNames) | 1350 PassRefPtr<NodeList> Node::getElementsByClassName(const String& classNames) |
1351 { | 1351 { |
1352 return ensureRareData().ensureNodeLists().addCacheWithName<ClassNodeList>(th
is, ClassNodeListType, classNames); | 1352 return ensureRareData().ensureNodeLists().addCacheWithName<ClassNodeList>(th
is, ClassNodeListType, classNames); |
1353 } | 1353 } |
1354 | 1354 |
1355 PassRefPtr<RadioNodeList> Node::radioNodeList(const AtomicString& name) | 1355 PassRefPtr<RadioNodeList> Node::radioNodeList(const AtomicString& name, bool onl
yMatchImgElements) |
1356 { | 1356 { |
1357 ASSERT(hasTagName(formTag) || hasTagName(fieldsetTag)); | 1357 ASSERT(hasTagName(formTag) || hasTagName(fieldsetTag)); |
| 1358 if (onlyMatchImgElements) |
| 1359 return static_pointer_cast<RadioNodeList>(ensureRareData().ensureNodeLis
ts().addCacheWithAtomicName<RadioImgNodeList>(this, RadioNodeListType, name)); |
| 1360 |
1358 return ensureRareData().ensureNodeLists().addCacheWithAtomicName<RadioNodeLi
st>(this, RadioNodeListType, name); | 1361 return ensureRareData().ensureNodeLists().addCacheWithAtomicName<RadioNodeLi
st>(this, RadioNodeListType, name); |
1359 } | 1362 } |
1360 | 1363 |
1361 PassRefPtr<Element> Node::querySelector(const AtomicString& selectors, Exception
State& exceptionState) | 1364 PassRefPtr<Element> Node::querySelector(const AtomicString& selectors, Exception
State& exceptionState) |
1362 { | 1365 { |
1363 if (selectors.isEmpty()) { | 1366 if (selectors.isEmpty()) { |
1364 exceptionState.throwDOMException(SyntaxError, "The provided selector is
empty."); | 1367 exceptionState.throwDOMException(SyntaxError, "The provided selector is
empty."); |
1365 return 0; | 1368 return 0; |
1366 } | 1369 } |
1367 | 1370 |
(...skipping 1369 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2737 node->showTreeForThis(); | 2740 node->showTreeForThis(); |
2738 } | 2741 } |
2739 | 2742 |
2740 void showNodePath(const WebCore::Node* node) | 2743 void showNodePath(const WebCore::Node* node) |
2741 { | 2744 { |
2742 if (node) | 2745 if (node) |
2743 node->showNodePathForThis(); | 2746 node->showNodePathForThis(); |
2744 } | 2747 } |
2745 | 2748 |
2746 #endif | 2749 #endif |
OLD | NEW |