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

Unified Diff: Source/core/html/forms/RangeInputType.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/RangeInputType.cpp
diff --git a/Source/core/html/forms/RangeInputType.cpp b/Source/core/html/forms/RangeInputType.cpp
index 3678a3f5549561d92aa954c2c1f534899ef78673..76a5c3e6c4b504b7e311164242efbcd1c23c9c0f 100644
--- a/Source/core/html/forms/RangeInputType.cpp
+++ b/Source/core/html/forms/RangeInputType.cpp
@@ -44,6 +44,7 @@
#include "core/dom/TouchList.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"
@@ -346,11 +347,10 @@ void RangeInputType::updateTickMarkValues()
HTMLDataListElement* dataList = element().dataList();
if (!dataList)
return;
- RefPtrWillBeRawPtr<HTMLCollection> options = dataList->options();
+ RefPtrWillBeRawPtr<HTMLDataListOptionsCollection> options = dataList->options();
m_tickMarkValues.reserveCapacity(options->length());
for (unsigned i = 0; i < options->length(); ++i) {
- Element* element = options->item(i);
- HTMLOptionElement* optionElement = toHTMLOptionElement(element);
+ HTMLOptionElement* optionElement = options->item(i);
String optionValue = optionElement->value();
if (!this->element().isValidValue(optionValue))
continue;

Powered by Google App Engine
This is Rietveld 408576698