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

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

Issue 1220883007: [dom] support iterable<> NodeList (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 5 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
Index: Source/core/html/HTMLCollection.h
diff --git a/Source/core/html/HTMLCollection.h b/Source/core/html/HTMLCollection.h
index 2270e882dae029a62ab36cefed8ec4d78d483826..1a21e0c90e9af532e35d58e6c83a5302cae754a9 100644
--- a/Source/core/html/HTMLCollection.h
+++ b/Source/core/html/HTMLCollection.h
@@ -24,6 +24,7 @@
#ifndef HTMLCollection_h
#define HTMLCollection_h
+#include "bindings/core/v8/Iterable.h"
#include "core/CoreExport.h"
#include "core/dom/LiveNodeListBase.h"
#include "core/html/CollectionItemsCache.h"
@@ -32,7 +33,7 @@
namespace blink {
-class CORE_EXPORT HTMLCollection : public RefCountedWillBeGarbageCollectedFinalized<HTMLCollection>, public ScriptWrappable, public LiveNodeListBase {
+class CORE_EXPORT HTMLCollection : public RefCountedWillBeGarbageCollectedFinalized<HTMLCollection>, public ScriptWrappable, public ValueIterable<Element*>, public LiveNodeListBase {
DEFINE_WRAPPERTYPEINFO();
WILL_BE_USING_GARBAGE_COLLECTED_MIXIN(HTMLCollection);
public:
@@ -147,6 +148,8 @@ private:
document.unregisterNodeListWithIdNameCache(this);
}
+ IterationSource* startIteration(ScriptState*, ExceptionState&) override;
+
const unsigned m_overridesItemAfter : 1;
const unsigned m_shouldOnlyIncludeDirectChildren : 1;
mutable OwnPtrWillBeMember<NamedItemCache> m_namedItemCache;

Powered by Google App Engine
This is Rietveld 408576698