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

Unified Diff: Source/core/html/WindowNameCollection.h

Issue 315473002: Stop having HTMLNameCollection override HTMLCollection::virtualItemAfter() (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Rebase Created 6 years, 7 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
Index: Source/core/html/WindowNameCollection.h
diff --git a/Source/core/html/WindowNameCollection.h b/Source/core/html/WindowNameCollection.h
new file mode 100644
index 0000000000000000000000000000000000000000..fc9408707c164e00c76ff28ee784049f8b79d824
--- /dev/null
+++ b/Source/core/html/WindowNameCollection.h
@@ -0,0 +1,30 @@
+// Copyright 2014 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef WindowNameCollection_h
+#define WindowNameCollection_h
+
+#include "core/html/HTMLNameCollection.h"
+
+namespace WebCore {
+
+class WindowNameCollection FINAL : public HTMLNameCollection {
+public:
+ static PassRefPtrWillBeRawPtr<WindowNameCollection> create(ContainerNode& document, CollectionType type, const AtomicString& name)
+ {
+ ASSERT_UNUSED(type, type == WindowNamedItems);
+ return adoptRefWillBeNoop(new WindowNameCollection(document, name));
+ }
+
+ bool elementMatches(const Element&) const;
+
+private:
+ WindowNameCollection(ContainerNode& document, const AtomicString& name);
+};
+
+DEFINE_TYPE_CASTS(WindowNameCollection, LiveNodeListBase, collection, collection->type() == WindowNamedItems, collection.type() == WindowNamedItems);
+
+} // namespace WebCore
+
+#endif // WindowNameCollection_h

Powered by Google App Engine
This is Rietveld 408576698