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

Unified Diff: Source/core/html/forms/ColorInputType.cpp

Issue 488763002: Introduce HTMLDataListOptionsCollection subclass for HTMLCollection (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 4 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/forms/ColorInputType.cpp
diff --git a/Source/core/html/forms/ColorInputType.cpp b/Source/core/html/forms/ColorInputType.cpp
index 7c03cd600ef3f9cd618e3c95539db878b6561aa2..1020281ba861c15ab5b4706ac691784a29ee21ba 100644
--- a/Source/core/html/forms/ColorInputType.cpp
+++ b/Source/core/html/forms/ColorInputType.cpp
@@ -38,6 +38,7 @@
#include "core/events/MouseEvent.h"
#include "core/dom/shadow/ShadowRoot.h"
#include "core/html/HTMLDataListElement.h"
+#include "core/html/HTMLDataListOptionsCollection.h"
#include "core/html/HTMLDivElement.h"
#include "core/html/HTMLInputElement.h"
#include "core/html/HTMLOptionElement.h"
@@ -236,8 +237,8 @@ Vector<ColorSuggestion> ColorInputType::suggestions() const
Vector<ColorSuggestion> suggestions;
HTMLDataListElement* dataList = element().dataList();
if (dataList) {
- RefPtrWillBeRawPtr<HTMLCollection> options = dataList->options();
- for (unsigned i = 0; HTMLOptionElement* option = toHTMLOptionElement(options->item(i)); i++) {
+ RefPtrWillBeRawPtr<HTMLDataListOptionsCollection> options = dataList->options();
+ for (unsigned i = 0; HTMLOptionElement* option = options->item(i); i++) {
if (!element().isValidValue(option->value()))
continue;
Color color;

Powered by Google App Engine
This is Rietveld 408576698