Bug 98240 - Implement DataList UI for input type time on chromium
Summary: Implement DataList UI for input type time on chromium
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Forms (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Keishi Hattori
URL:
Keywords: WebExposed
Depends on:
Blocks:
 
Reported: 2012-10-03 01:19 PDT by Keishi Hattori
Modified: 2012-10-04 00:44 PDT (History)
8 users (show)

See Also:


Attachments
Patch (89.96 KB, patch)
2012-10-03 01:31 PDT, Keishi Hattori
no flags Details | Formatted Diff | Diff
Patch (92.04 KB, patch)
2012-10-03 05:05 PDT, Keishi Hattori
no flags Details | Formatted Diff | Diff
Patch (93.34 KB, patch)
2012-10-03 05:21 PDT, Keishi Hattori
no flags Details | Formatted Diff | Diff
Patch (93.30 KB, patch)
2012-10-03 05:26 PDT, Keishi Hattori
no flags Details | Formatted Diff | Diff
Patch (96.55 KB, patch)
2012-10-03 07:41 PDT, Keishi Hattori
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Keishi Hattori 2012-10-03 01:19:40 PDT
Implement DataList UI for input type time on chromium
Comment 1 Keishi Hattori 2012-10-03 01:31:51 PDT
Created attachment 166825 [details]
Patch
Comment 2 Kent Tamura 2012-10-03 02:21:45 PDT
Comment on attachment 166825 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=166825&action=review

> Source/WebCore/css/html.css:573
> +    display: -webkit-box;
> +    -webkit-box-align: center;

nit:
Can you use the standard flex box instead of the legacy one?

  display: -webkit-flex;
  -webkit-align-content: center;

I thinks this works.

> Source/WebCore/html/BaseMultipleFieldsDateAndTimeInputType.cpp:96
>      , m_dateTimeEditElement(0)
> +    , m_pickerIndicatorIsVisible(false)

should initialize m_pickerIndicatorElement.

> Source/WebCore/html/BaseMultipleFieldsDateAndTimeInputType.cpp:118
> +{    

trailing whitespace

> Source/WebCore/html/BaseMultipleFieldsDateAndTimeInputType.cpp:119
> +    DEFINE_STATIC_LOCAL(AtomicString, dateAndTimeInputContainerPseudoId, ("-webkit-date-and-time-container"));

should be ("-webkit-date-and-time-container", AtomicString::ConstructFromLiteral)

> Source/WebCore/html/BaseMultipleFieldsDateAndTimeInputType.cpp:275
> +    HTMLDataListElement* dataList = element()->dataList();
> +    if (dataList) {

nit:
if (HTMLDataListElement* dataList = element()->dataList()) {

> Source/WebCore/html/BaseMultipleFieldsDateAndTimeInputType.cpp:292
> +    m_pickerIndicatorElement->setInlineStyleProperty(CSSPropertyDisplay, CSSValueNone);

nice to have ASSERT(m_pickerIndicatorElement) ?

> Source/WebCore/html/BaseMultipleFieldsDateAndTimeInputType.cpp:300
> +    m_pickerIndicatorElement->removeInlineStyleProperty(CSSPropertyDisplay);

ditto.

> LayoutTests/ChangeLog:32
> +        * platform/chromium/fast/forms/time/time-suggestion-picker-appearance-expected.txt: Added.
> +        * platform/chromium/fast/forms/time/time-suggestion-picker-appearance-rtl-expected.txt: Added.
> +        * platform/chromium/fast/forms/time/time-suggestion-picker-appearance-rtl.html: Added.
> +        * platform/chromium/fast/forms/time/time-suggestion-picker-appearance-with-scroll-bar-expected.txt: Added.
> +        * platform/chromium/fast/forms/time/time-suggestion-picker-appearance-with-scroll-bar.html: Added.
> +        * platform/chromium/fast/forms/time/time-suggestion-picker-appearance.html: Added.
> +        * platform/chromium/fast/forms/time/time-suggestion-picker-key-operations-expected.txt: Added.
> +        * platform/chromium/fast/forms/time/time-suggestion-picker-key-operations.html: Added.
> +        * platform/chromium/fast/forms/time/time-suggestion-picker-mouse-operations-expected.txt: Added.
> +        * platform/chromium/fast/forms/time/time-suggestion-picker-mouse-operations.html: Added.

should update chromium/TestExpectations for new tests on non-Mac.

> LayoutTests/fast/forms/time-multiple-fields/time-multiple-fields-spinbutton-click-in-iframe.html:5
> +<script src="../resources/common.js"></script>

Why did you add common.js to this?

> LayoutTests/platform/chromium/fast/forms/time/time-suggestion-picker-appearance-rtl.html:31
> +function sendKey(input, keyName, ctrlKey, altKey) {
> +    var event = document.createEvent('KeyboardEvent');
> +    event.initKeyboardEvent('keydown', true, true, document.defaultView, keyName, 0, ctrlKey, altKey);
> +    input.dispatchEvent(event);
> +}

suggestion-picker-common.js has it.

> LayoutTests/platform/chromium/fast/forms/time/time-suggestion-picker-appearance-with-scroll-bar.html:32
> +function sendKey(input, keyName, ctrlKey, altKey) {
> +    var event = document.createEvent('KeyboardEvent');
> +    event.initKeyboardEvent('keydown', true, true, document.defaultView, keyName, 0, ctrlKey, altKey);
> +    input.dispatchEvent(event);
> +}

ditto.

> LayoutTests/platform/chromium/fast/forms/time/time-suggestion-picker-appearance.html:9
> +    <option>01:02</option>

We should have some option values with seconds, milliseconds, afternoon times.

> LayoutTests/platform/chromium/fast/forms/time/time-suggestion-picker-appearance.html:34
> +function sendKey(input, keyName, ctrlKey, altKey) {
> +    var event = document.createEvent('KeyboardEvent');
> +    event.initKeyboardEvent('keydown', true, true, document.defaultView, keyName, 0, ctrlKey, altKey);
> +    input.dispatchEvent(event);
> +}

suggestion-picker-common.js has it.
Comment 3 Keishi Hattori 2012-10-03 05:05:16 PDT
Created attachment 166859 [details]
Patch
Comment 4 Kent Tamura 2012-10-03 05:13:30 PDT
Comment on attachment 166859 [details]
Patch

Please update LayoutTests/platform/chromium/TestExpectations so that all of new tests are expected to fail on all platforms including Mac. Your Bug 98237 will update the image results of these tests.
Comment 5 Keishi Hattori 2012-10-03 05:21:03 PDT
Created attachment 166863 [details]
Patch
Comment 6 Keishi Hattori 2012-10-03 05:26:14 PDT
Created attachment 166865 [details]
Patch
Comment 7 WebKit Review Bot 2012-10-03 07:09:29 PDT
Comment on attachment 166865 [details]
Patch

Rejecting attachment 166865 [details] from commit-queue.

New failing tests:
fast/forms/datalist/input-list.html
platform/chromium/fast/forms/date/date-suggestion-picker-mouse-operations.html
fast/forms/number/number-spinbutton-click-in-iframe.html
Full output: http://queues.webkit.org/results/14136611
Comment 8 WebKit Review Bot 2012-10-03 07:19:44 PDT
Comment on attachment 166865 [details]
Patch

Attachment 166865 [details] did not pass chromium-ews (chromium-xvfb):
Output: http://queues.webkit.org/results/14125792

New failing tests:
fast/forms/datalist/input-list.html
platform/chromium/fast/forms/date/date-suggestion-picker-mouse-operations.html
fast/forms/number/number-spinbutton-click-in-iframe.html
Comment 9 Keishi Hattori 2012-10-03 07:41:48 PDT
Created attachment 166890 [details]
Patch
Comment 10 WebKit Review Bot 2012-10-03 08:42:01 PDT
Comment on attachment 166890 [details]
Patch

Clearing flags on attachment: 166890

Committed r130293: <http://trac.webkit.org/changeset/130293>
Comment 11 WebKit Review Bot 2012-10-03 08:42:04 PDT
All reviewed patches have been landed.  Closing bug.