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

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

Issue 176933013: Pass rootNode by reference when constructing node lists / collections (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Rebase Created 6 years, 10 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/NodeRareData.h ('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 393741ed8d1fccfc472b8f0e761aae676f1c3ac1..7d4782a892478f406d74b0aaf74d06ed19078280 100644
--- a/Source/core/dom/TagCollection.h
+++ b/Source/core/dom/TagCollection.h
@@ -33,13 +33,13 @@ namespace WebCore {
// Collection that limits to a particular tag.
class TagCollection : public HTMLCollection {
public:
- static PassRefPtr<TagCollection> create(ContainerNode* rootNode, const AtomicString& namespaceURI, const AtomicString& localName)
+ static PassRefPtr<TagCollection> create(ContainerNode& rootNode, const AtomicString& namespaceURI, const AtomicString& localName)
{
ASSERT(namespaceURI != starAtom);
return adoptRef(new TagCollection(rootNode, TagCollectionType, namespaceURI, localName));
}
- static PassRefPtr<TagCollection> create(ContainerNode* rootNode, CollectionType type, const AtomicString& localName)
+ static PassRefPtr<TagCollection> create(ContainerNode& rootNode, CollectionType type, const AtomicString& localName)
{
ASSERT_UNUSED(type, type == TagCollectionType);
return adoptRef(new TagCollection(rootNode, TagCollectionType, starAtom, localName));
@@ -50,7 +50,7 @@ public:
bool elementMatches(const Element&) const;
protected:
- TagCollection(ContainerNode* rootNode, CollectionType, const AtomicString& namespaceURI, const AtomicString& localName);
+ TagCollection(ContainerNode& rootNode, CollectionType, const AtomicString& namespaceURI, const AtomicString& localName);
AtomicString m_namespaceURI;
AtomicString m_localName;
@@ -58,7 +58,7 @@ protected:
class HTMLTagCollection FINAL : public TagCollection {
public:
- static PassRefPtr<HTMLTagCollection> create(ContainerNode* rootNode, CollectionType type, const AtomicString& localName)
+ static PassRefPtr<HTMLTagCollection> create(ContainerNode& rootNode, CollectionType type, const AtomicString& localName)
{
ASSERT_UNUSED(type, type == HTMLTagCollectionType);
return adoptRef(new HTMLTagCollection(rootNode, localName));
@@ -67,7 +67,7 @@ public:
bool elementMatches(const Element&) const;
private:
- HTMLTagCollection(ContainerNode* rootNode, const AtomicString& localName);
+ HTMLTagCollection(ContainerNode& rootNode, const AtomicString& localName);
AtomicString m_loweredLocalName;
};
« no previous file with comments | « Source/core/dom/NodeRareData.h ('k') | Source/core/dom/TagCollection.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698