Chromium Code Reviews| Index: Source/core/html/HTMLInputElement.cpp |
| diff --git a/Source/core/html/HTMLInputElement.cpp b/Source/core/html/HTMLInputElement.cpp |
| index c35f154fd81cdb6d015e4ea478b9121db9dec279..8a92a5b54c8a06e4081b658cfa84eb60af43bc61 100644 |
| --- a/Source/core/html/HTMLInputElement.cpp |
| +++ b/Source/core/html/HTMLInputElement.cpp |
| @@ -1845,9 +1845,11 @@ bool HTMLInputElement::setupDateTimeChooserParameters(DateTimeChooserParameters& |
| for (unsigned i = 0; HTMLOptionElement* option = toHTMLOptionElement(options->item(i)); ++i) { |
| if (!isValidValue(option->value())) |
| continue; |
| - parameters.suggestionValues.append(sanitizeValue(option->value())); |
| - parameters.localizedSuggestionValues.append(localizeValue(option->value())); |
| - parameters.suggestionLabels.append(option->value() == option->label() ? String() : option->label()); |
| + DateTimeSuggestion suggestion; |
| + suggestion.value = m_inputType->parseToNumber(option->value(), -1).toDouble(); |
|
tkent
2013/11/26 13:34:35
Why -1?
If option->value() is invalid, shouldn't w
keishi
2013/11/27 07:30:57
Done.
|
| + suggestion.localizedValue = localizeValue(option->value()); |
| + suggestion.label = option->value() == option->label() ? String() : option->label(); |
| + parameters.suggestions.append(suggestion); |
| } |
| } |
| } |