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

Side by Side Diff: Source/core/html/HTMLInputElement.cpp

Issue 62083004: Transfer date/time value to the chooser as a double (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@datetime3
Patch Set: Created 7 years, 1 month 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 unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org)
3 * (C) 1999 Antti Koivisto (koivisto@kde.org) 3 * (C) 1999 Antti Koivisto (koivisto@kde.org)
4 * (C) 2001 Dirk Mueller (mueller@kde.org) 4 * (C) 2001 Dirk Mueller (mueller@kde.org)
5 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All r ights reserved. 5 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All r ights reserved.
6 * (C) 2006 Alexey Proskuryakov (ap@nypop.com) 6 * (C) 2006 Alexey Proskuryakov (ap@nypop.com)
7 * Copyright (C) 2007 Samuel Weinig (sam@webkit.org) 7 * Copyright (C) 2007 Samuel Weinig (sam@webkit.org)
8 * Copyright (C) 2010 Google Inc. All rights reserved. 8 * Copyright (C) 2010 Google Inc. All rights reserved.
9 * Copyright (C) 2008 Torch Mobile Inc. All rights reserved. (http://www.torchmo bile.com/) 9 * Copyright (C) 2008 Torch Mobile Inc. All rights reserved. (http://www.torchmo bile.com/)
10 * Copyright (C) 2012 Samsung Electronics. All rights reserved. 10 * Copyright (C) 2012 Samsung Electronics. All rights reserved.
(...skipping 1814 matching lines...) Expand 10 before | Expand all | Expand 10 after
1825 if (stepRange.hasStep()) { 1825 if (stepRange.hasStep()) {
1826 parameters.step = stepRange.step().toDouble(); 1826 parameters.step = stepRange.step().toDouble();
1827 parameters.stepBase = stepRange.stepBase().toDouble(); 1827 parameters.stepBase = stepRange.stepBase().toDouble();
1828 } else { 1828 } else {
1829 parameters.step = 1.0; 1829 parameters.step = 1.0;
1830 parameters.stepBase = 0; 1830 parameters.stepBase = 0;
1831 } 1831 }
1832 1832
1833 parameters.anchorRectInRootView = document().view()->contentsToRootView(pixe lSnappedBoundingBox()); 1833 parameters.anchorRectInRootView = document().view()->contentsToRootView(pixe lSnappedBoundingBox());
1834 parameters.currentValue = value(); 1834 parameters.currentValue = value();
1835 parameters.doubleValue = m_inputType->valueAsDouble();
1835 parameters.isAnchorElementRTL = computedStyle()->direction() == RTL; 1836 parameters.isAnchorElementRTL = computedStyle()->direction() == RTL;
1836 if (RuntimeEnabledFeatures::dataListElementEnabled()) { 1837 if (RuntimeEnabledFeatures::dataListElementEnabled()) {
1837 if (HTMLDataListElement* dataList = this->dataList()) { 1838 if (HTMLDataListElement* dataList = this->dataList()) {
1838 RefPtr<HTMLCollection> options = dataList->options(); 1839 RefPtr<HTMLCollection> options = dataList->options();
1839 for (unsigned i = 0; HTMLOptionElement* option = toHTMLOptionElement (options->item(i)); ++i) { 1840 for (unsigned i = 0; HTMLOptionElement* option = toHTMLOptionElement (options->item(i)); ++i) {
1840 if (!isValidValue(option->value())) 1841 if (!isValidValue(option->value()))
1841 continue; 1842 continue;
1842 parameters.suggestionValues.append(sanitizeValue(option->value() )); 1843 parameters.suggestionValues.append(sanitizeValue(option->value() ));
1843 parameters.localizedSuggestionValues.append(localizeValue(option ->value())); 1844 parameters.localizedSuggestionValues.append(localizeValue(option ->value()));
1844 parameters.suggestionLabels.append(option->value() == option->la bel() ? String() : option->label()); 1845 parameters.suggestionLabels.append(option->value() == option->la bel() ? String() : option->label());
(...skipping 14 matching lines...) Expand all
1859 } 1860 }
1860 1861
1861 #if ENABLE(INPUT_MULTIPLE_FIELDS_UI) 1862 #if ENABLE(INPUT_MULTIPLE_FIELDS_UI)
1862 PassRefPtr<RenderStyle> HTMLInputElement::customStyleForRenderer() 1863 PassRefPtr<RenderStyle> HTMLInputElement::customStyleForRenderer()
1863 { 1864 {
1864 return m_inputTypeView->customStyleForRenderer(originalStyleForRenderer()); 1865 return m_inputTypeView->customStyleForRenderer(originalStyleForRenderer());
1865 } 1866 }
1866 #endif 1867 #endif
1867 1868
1868 } // namespace 1869 } // namespace
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698