Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(740)

Unified Diff: Source/core/dom/TagCollection.h

Issue 355163004: Move HTMLTagCollection to its own file (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/core/dom/ContainerNode.cpp ('k') | Source/core/dom/TagCollection.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/dom/TagCollection.h
diff --git a/Source/core/dom/TagCollection.h b/Source/core/dom/TagCollection.h
index 6b97db7f2a765918f046cb4b8143d9856f1f0c71..f05ad7b1449ccf1260d2f6754e5ea55f84e04ef4 100644
--- a/Source/core/dom/TagCollection.h
+++ b/Source/core/dom/TagCollection.h
@@ -24,7 +24,6 @@
#ifndef TagCollection_h
#define TagCollection_h
-#include "core/dom/Element.h"
#include "core/html/HTMLCollection.h"
#include "wtf/text/AtomicString.h"
@@ -58,36 +57,6 @@ protected:
DEFINE_TYPE_CASTS(TagCollection, LiveNodeListBase, collection, collection->type() == TagCollectionType, collection.type() == TagCollectionType);
-class HTMLTagCollection FINAL : public TagCollection {
-public:
- static PassRefPtrWillBeRawPtr<HTMLTagCollection> create(ContainerNode& rootNode, CollectionType type, const AtomicString& localName)
- {
- ASSERT_UNUSED(type, type == HTMLTagCollectionType);
- return adoptRefWillBeNoop(new HTMLTagCollection(rootNode, localName));
- }
-
- bool elementMatches(const Element&) const;
-
-private:
- HTMLTagCollection(ContainerNode& rootNode, const AtomicString& localName);
-
- AtomicString m_loweredLocalName;
-};
-
-DEFINE_TYPE_CASTS(HTMLTagCollection, LiveNodeListBase, collection, collection->type() == HTMLTagCollectionType, collection.type() == HTMLTagCollectionType);
-
-inline bool HTMLTagCollection::elementMatches(const Element& testElement) const
-{
- // Implements http://dvcs.w3.org/hg/domcore/raw-file/tip/Overview.html#concept-getelementsbytagname
- if (m_localName != starAtom) {
- const AtomicString& localName = testElement.isHTMLElement() ? m_loweredLocalName : m_localName;
- if (localName != testElement.localName())
- return false;
- }
- ASSERT(m_namespaceURI == starAtom);
- return true;
-}
-
} // namespace WebCore
#endif // TagCollection_h
« no previous file with comments | « Source/core/dom/ContainerNode.cpp ('k') | Source/core/dom/TagCollection.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698