Commit 3f18db00 authored by Liviu Tinta's avatar Liviu Tinta Committed by Commit Bot

Remove the RuntimeFeature FractionalMouseEvent flag including all the virtual...

Remove the RuntimeFeature FractionalMouseEvent flag including all the virtual tests that go with it.

Bug: 1041985
Change-Id: Ib32f3a0292bab5ef4822f02ab64c2bee7b06de1b
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2020563
Commit-Queue: Dave Tapuska <dtapuska@chromium.org>
Reviewed-by: default avatarDave Tapuska <dtapuska@chromium.org>
Cr-Commit-Position: refs/heads/master@{#737403}
parent 31fd8020
...@@ -561,9 +561,7 @@ double MouseEvent::offsetX() { ...@@ -561,9 +561,7 @@ double MouseEvent::offsetX() {
return 0; return 0;
if (!has_cached_relative_position_) if (!has_cached_relative_position_)
ComputeRelativePosition(); ComputeRelativePosition();
return (RuntimeEnabledFeatures::FractionalMouseEventEnabled()) return std::round(offset_location_.X());
? offset_location_.X()
: std::round(offset_location_.X());
} }
double MouseEvent::offsetY() { double MouseEvent::offsetY() {
...@@ -571,9 +569,7 @@ double MouseEvent::offsetY() { ...@@ -571,9 +569,7 @@ double MouseEvent::offsetY() {
return 0; return 0;
if (!has_cached_relative_position_) if (!has_cached_relative_position_)
ComputeRelativePosition(); ComputeRelativePosition();
return (RuntimeEnabledFeatures::FractionalMouseEventEnabled()) return std::round(offset_location_.Y());
? offset_location_.Y()
: std::round(offset_location_.Y());
} }
} // namespace blink } // namespace blink
...@@ -142,27 +142,19 @@ class CORE_EXPORT MouseEvent : public UIEventWithKeyState { ...@@ -142,27 +142,19 @@ class CORE_EXPORT MouseEvent : public UIEventWithKeyState {
// Note that these values are adjusted to counter the effects of zoom, so that // Note that these values are adjusted to counter the effects of zoom, so that
// values exposed via DOM APIs are invariant under zooming. // values exposed via DOM APIs are invariant under zooming.
virtual double screenX() const { virtual double screenX() const {
return (RuntimeEnabledFeatures::FractionalMouseEventEnabled()) return static_cast<int>(screen_location_.X());
? screen_location_.X()
: static_cast<int>(screen_location_.X());
} }
virtual double screenY() const { virtual double screenY() const {
return (RuntimeEnabledFeatures::FractionalMouseEventEnabled()) return static_cast<int>(screen_location_.Y());
? screen_location_.Y()
: static_cast<int>(screen_location_.Y());
} }
virtual double clientX() const { virtual double clientX() const {
return (RuntimeEnabledFeatures::FractionalMouseEventEnabled()) return static_cast<int>(client_location_.X());
? client_location_.X()
: static_cast<int>(client_location_.X());
} }
virtual double clientY() const { virtual double clientY() const {
return (RuntimeEnabledFeatures::FractionalMouseEventEnabled()) return static_cast<int>(client_location_.Y());
? client_location_.Y()
: static_cast<int>(client_location_.Y());
} }
int movementX() const { return movement_delta_.X(); } int movementX() const { return movement_delta_.X(); }
...@@ -174,17 +166,9 @@ class CORE_EXPORT MouseEvent : public UIEventWithKeyState { ...@@ -174,17 +166,9 @@ class CORE_EXPORT MouseEvent : public UIEventWithKeyState {
virtual double offsetX(); virtual double offsetX();
virtual double offsetY(); virtual double offsetY();
virtual double pageX() const { virtual double pageX() const { return static_cast<int>(page_location_.X()); }
return (RuntimeEnabledFeatures::FractionalMouseEventEnabled())
? page_location_.X()
: static_cast<int>(page_location_.X());
}
virtual double pageY() const { virtual double pageY() const { return static_cast<int>(page_location_.Y()); }
return (RuntimeEnabledFeatures::FractionalMouseEventEnabled())
? page_location_.Y()
: static_cast<int>(page_location_.Y());
}
double x() const { return clientX(); } double x() const { return clientX(); }
double y() const { return clientY(); } double y() const { return clientY(); }
...@@ -202,20 +186,18 @@ class CORE_EXPORT MouseEvent : public UIEventWithKeyState { ...@@ -202,20 +186,18 @@ class CORE_EXPORT MouseEvent : public UIEventWithKeyState {
void Trace(blink::Visitor*) override; void Trace(blink::Visitor*) override;
DoublePoint screen_location_;
DoublePoint client_location_;
DoublePoint page_location_; // zoomed CSS pixels
DoublePoint offset_location_; // zoomed CSS pixels
protected: protected:
int16_t RawButton() const { return button_; } int16_t RawButton() const { return button_; }
void ReceivedTarget() override; void ReceivedTarget() override;
// TODO(eirage): Move these coordinates related field back to private
// when MouseEvent fractional flag is removed.
void ComputeRelativePosition(); void ComputeRelativePosition();
DoublePoint screen_location_;
DoublePoint client_location_;
DoublePoint page_location_; // zoomed CSS pixels
DoublePoint offset_location_; // zoomed CSS pixels
bool has_cached_relative_position_ = false; bool has_cached_relative_position_ = false;
private: private:
......
...@@ -777,9 +777,6 @@ ...@@ -777,9 +777,6 @@
name: "ForceTallerSelectPopup", name: "ForceTallerSelectPopup",
status: {"ChromeOS": "stable"}, status: {"ChromeOS": "stable"},
}, },
{
name: "FractionalMouseEvent",
},
{ {
name: "FractionalScrollOffsets", name: "FractionalScrollOffsets",
status: "experimental", status: "experimental",
......
...@@ -19,7 +19,6 @@ virtual/stable/* [ Skip ] ...@@ -19,7 +19,6 @@ virtual/stable/* [ Skip ]
# For now we track the failures of the base tests of the following virtual suites. # For now we track the failures of the base tests of the following virtual suites.
virtual/exotic-color-space/images/* [ Skip ] virtual/exotic-color-space/images/* [ Skip ]
virtual/gpu-rasterization/images/* [ Skip ] virtual/gpu-rasterization/images/* [ Skip ]
virtual/mouseevent_fractional/fast/events/touch/* [ Skip ]
virtual/scroll_customization/fast/events/touch/* [ Skip ] virtual/scroll_customization/fast/events/touch/* [ Skip ]
virtual/threaded/printing/* [ Skip ] virtual/threaded/printing/* [ Skip ]
virtual/threaded/http/tests/devtools/tracing/* [ Skip ] virtual/threaded/http/tests/devtools/tracing/* [ Skip ]
......
...@@ -499,7 +499,6 @@ crbug.com/1035582 paint/invalidation/svg/focus-element.html [ Failure ] ...@@ -499,7 +499,6 @@ crbug.com/1035582 paint/invalidation/svg/focus-element.html [ Failure ]
crbug.com/1035582 paint/invalidation/svg/scrolling-embedded-svg-file-image-repaint-problem.html [ Failure ] crbug.com/1035582 paint/invalidation/svg/scrolling-embedded-svg-file-image-repaint-problem.html [ Failure ]
crbug.com/1035582 paint/invalidation/svg/transform-focus-ring-repaint.html [ Failure ] crbug.com/1035582 paint/invalidation/svg/transform-focus-ring-repaint.html [ Failure ]
crbug.com/1035582 paint/invalidation/table/caret-contenteditable-content-after.html [ Failure ] crbug.com/1035582 paint/invalidation/table/caret-contenteditable-content-after.html [ Failure ]
crbug.com/1035582 virtual/mouseevent_fractional/fast/events/sequential-focus-navigation-starting-point.html [ Skip ]
crbug.com/1035582 external/wpt/css/css-pseudo/selection-text-shadow-016.html [ Failure ] crbug.com/1035582 external/wpt/css/css-pseudo/selection-text-shadow-016.html [ Failure ]
crbug.com/1035582 external/wpt/css/css-text-decor/text-decoration-subelements-001.html [ Failure ] crbug.com/1035582 external/wpt/css/css-text-decor/text-decoration-subelements-001.html [ Failure ]
crbug.com/1035582 paint/background/background-clip-text-descendants.html [ Failure ] crbug.com/1035582 paint/background/background-clip-text-descendants.html [ Failure ]
......
...@@ -1574,16 +1574,6 @@ crbug.com/982194 virtual/layout_ng_flex_box/external/wpt/css/vendor-imports/mozi ...@@ -1574,16 +1574,6 @@ crbug.com/982194 virtual/layout_ng_flex_box/external/wpt/css/vendor-imports/mozi
crbug.com/982194 virtual/layout_ng_flex_box/external/wpt/css/vendor-imports/mozilla/mozilla-central-reftests/flexbox/flexbox-min-width-auto-002c.html [ Failure ] crbug.com/982194 virtual/layout_ng_flex_box/external/wpt/css/vendor-imports/mozilla/mozilla-central-reftests/flexbox/flexbox-min-width-auto-002c.html [ Failure ]
crbug.com/982194 virtual/layout_ng_flex_box/external/wpt/css/vendor-imports/mozilla/mozilla-central-reftests/flexbox/flexbox-paint-ordering-002.xhtml [ Failure ] crbug.com/982194 virtual/layout_ng_flex_box/external/wpt/css/vendor-imports/mozilla/mozilla-central-reftests/flexbox/flexbox-paint-ordering-002.xhtml [ Failure ]
crbug.com/982194 virtual/lazyload-image/http/tests/lazyload/style-dimension.html [ Pass ] crbug.com/982194 virtual/lazyload-image/http/tests/lazyload/style-dimension.html [ Pass ]
crbug.com/779170 virtual/mouseevent_fractional/fast/events/clientXY-in-zoom-and-scroll.html [ Pass ]
crbug.com/663847 virtual/mouseevent_fractional/fast/events/context-no-deselect.html [ Failure ]
crbug.com/346473 virtual/mouseevent_fractional/fast/events/drag-on-mouse-move-cancelled.html [ Failure ]
crbug.com/982194 virtual/mouseevent_fractional/fast/events/mouse-relative-position.html [ Failure ]
crbug.com/722212 virtual/mouseevent_fractional/fast/events/pointerevents/mouse-pointer-event-properties.html [ Failure ]
crbug.com/982194 virtual/mouseevent_fractional/fast/events/touch/compositor-touch-hit-rects-list-translate.html [ Failure ]
crbug.com/591099 virtual/mouseevent_fractional/fast/events/touch/compositor-touch-hit-rects.html [ Failure ]
crbug.com/874695 virtual/mouseevent_fractional/fast/events/touch/gesture/gesture-click.html [ Pass ]
crbug.com/874695 virtual/mouseevent_fractional/fast/events/touch/touch-slider-no-js-touch-listener.html [ Pass ]
crbug.com/779170 virtual/mouseevent_fractional/fast/events/zoom-dblclick.html [ Failure ]
crbug.com/982194 virtual/not-site-per-process/http/tests/devtools/debugger/fetch-breakpoints.js [ Pass Timeout ] crbug.com/982194 virtual/not-site-per-process/http/tests/devtools/debugger/fetch-breakpoints.js [ Pass Timeout ]
crbug.com/982194 virtual/off-main-thread-css-paint/external/wpt/css/css-paint-api/invalid-image-pending-script.https.html [ Pass ] crbug.com/982194 virtual/off-main-thread-css-paint/external/wpt/css/css-paint-api/invalid-image-pending-script.https.html [ Pass ]
crbug.com/982194 virtual/omt-worker-fetch/external/wpt/fetch/metadata/sec-fetch-dest/frame.tentative.https.sub.html [ Timeout ] crbug.com/982194 virtual/omt-worker-fetch/external/wpt/fetch/metadata/sec-fetch-dest/frame.tentative.https.sub.html [ Timeout ]
......
...@@ -73,9 +73,6 @@ crbug.com/862029 [ Linux ] virtual/threaded/http/tests/devtools/tracing/timeline ...@@ -73,9 +73,6 @@ crbug.com/862029 [ Linux ] virtual/threaded/http/tests/devtools/tracing/timeline
crbug.com/733494 [ Linux ] media/autoplay/document-user-activation.html [ Pass Failure ] crbug.com/733494 [ Linux ] media/autoplay/document-user-activation.html [ Pass Failure ]
crbug.com/733494 [ Linux ] virtual/audio-service/media/autoplay/document-user-activation.html [ Pass Failure ] crbug.com/733494 [ Linux ] virtual/audio-service/media/autoplay/document-user-activation.html [ Pass Failure ]
# Sheriff 2019-01-04
crbug.com/919117 [ Linux ] virtual/mouseevent_fractional/fast/events/middleClickAutoscroll-drag.html [ Pass Failure ]
# Sheriff 2019-01-07 # Sheriff 2019-01-07
crbug.com/919497 [ Linux ] virtual/threaded/http/tests/devtools/tracing/timeline-gpu-tasks.js [ Pass Failure ] crbug.com/919497 [ Linux ] virtual/threaded/http/tests/devtools/tracing/timeline-gpu-tasks.js [ Pass Failure ]
......
...@@ -40,8 +40,6 @@ fast/harness/results.html [ Skip ] ...@@ -40,8 +40,6 @@ fast/harness/results.html [ Skip ]
[ Linux ] editing/input/emacs-ctrl-o.html [ Skip ] [ Linux ] editing/input/emacs-ctrl-o.html [ Skip ]
[ Win ] fast/events/inputevents/inputevent-yank.html [ Skip ] [ Win ] fast/events/inputevents/inputevent-yank.html [ Skip ]
[ Linux ] fast/events/inputevents/inputevent-yank.html [ Skip ] [ Linux ] fast/events/inputevents/inputevent-yank.html [ Skip ]
[ Win ] virtual/mouseevent_fractional/fast/events/inputevents/inputevent-yank.html [ Skip ]
[ Linux ] virtual/mouseevent_fractional/fast/events/inputevents/inputevent-yank.html [ Skip ]
# Chrome Mac doesn't support Ctrl+Up/Down key-bindings. # Chrome Mac doesn't support Ctrl+Up/Down key-bindings.
[ Mac ] editing/input/ctrl-up-down.html [ Skip ] [ Mac ] editing/input/ctrl-up-down.html [ Skip ]
...@@ -50,8 +48,6 @@ fast/harness/results.html [ Skip ] ...@@ -50,8 +48,6 @@ fast/harness/results.html [ Skip ]
# this test will always fail. # this test will always fail.
[ Linux ] fast/events/option-tab.html [ Skip ] [ Linux ] fast/events/option-tab.html [ Skip ]
[ Win ] fast/events/option-tab.html [ Skip ] [ Win ] fast/events/option-tab.html [ Skip ]
[ Linux ] virtual/mouseevent_fractional/fast/events/option-tab.html [ Skip ]
[ Win ] virtual/mouseevent_fractional/fast/events/option-tab.html [ Skip ]
# This test only applies to overlay scrollbar platforms. # This test only applies to overlay scrollbar platforms.
[ Win ] fast/dom/partial-layout-overlay-scrollbars.html [ Skip ] [ Win ] fast/dom/partial-layout-overlay-scrollbars.html [ Skip ]
...@@ -91,13 +87,6 @@ crbug.com/1012590 [ Linux ] fast/overflow/rtl-scrollbar-drag-origin.html [ Skip ...@@ -91,13 +87,6 @@ crbug.com/1012590 [ Linux ] fast/overflow/rtl-scrollbar-drag-origin.html [ Skip
[ Mac ] fast/events/menu-key-context-menu-position.html [ Skip ] [ Mac ] fast/events/menu-key-context-menu-position.html [ Skip ]
[ Mac ] fast/events/menu-key-context-menu-reveal-focus.html [ Skip ] [ Mac ] fast/events/menu-key-context-menu-reveal-focus.html [ Skip ]
[ Mac ] fast/events/menu-key-context-menu.html [ Skip ] [ Mac ] fast/events/menu-key-context-menu.html [ Skip ]
[ Mac ] virtual/mouseevent_fractional/fast/events/context-menu-key-shift-f10-modifiers.html [ Skip ]
[ Mac ] virtual/mouseevent_fractional/fast/events/context-menu-key-shift-f10-prevent-default.html [ Skip ]
[ Mac ] virtual/mouseevent_fractional/fast/events/contextmenu-follows-focus.html [ Skip ]
[ Mac ] virtual/mouseevent_fractional/fast/events/menu-key-context-menu-document.html [ Skip ]
[ Mac ] virtual/mouseevent_fractional/fast/events/menu-key-context-menu-position.html [ Skip ]
[ Mac ] virtual/mouseevent_fractional/fast/events/menu-key-context-menu-reveal-focus.html [ Skip ]
[ Mac ] virtual/mouseevent_fractional/fast/events/menu-key-context-menu.html [ Skip ]
# Thumb snapping is not supported on Linux and Mac. # Thumb snapping is not supported on Linux and Mac.
[ Linux ] fast/scrolling/scrollbars/scrollbar-thumb-snapping.html [ Skip ] [ Linux ] fast/scrolling/scrollbars/scrollbar-thumb-snapping.html [ Skip ]
......
...@@ -567,9 +567,6 @@ crbug.com/874695 virtual/gpu-rasterization/images/color-profile-mask-image-svg.h ...@@ -567,9 +567,6 @@ crbug.com/874695 virtual/gpu-rasterization/images/color-profile-mask-image-svg.h
crbug.com/874695 virtual/gpu-rasterization/images/image-page-injected-script-crash.html [ Slow ] crbug.com/874695 virtual/gpu-rasterization/images/image-page-injected-script-crash.html [ Slow ]
crbug.com/874695 virtual/gpu-rasterization/images/webp-color-profile-lossless.html [ Slow ] crbug.com/874695 virtual/gpu-rasterization/images/webp-color-profile-lossless.html [ Slow ]
crbug.com/874695 virtual/gpu-rasterization/images/yuv-decode-eligible/color-profile-layer-filter.html [ Slow ] crbug.com/874695 virtual/gpu-rasterization/images/yuv-decode-eligible/color-profile-layer-filter.html [ Slow ]
crbug.com/874695 virtual/mouseevent_fractional/fast/events/middleClickAutoscroll-nested-divs-forbidden.html [ Slow ]
crbug.com/874695 virtual/mouseevent_fractional/fast/events/touch/gesture/gesture-click.html [ Slow ]
crbug.com/874695 virtual/mouseevent_fractional/fast/events/touch/touch-slider-no-js-touch-listener.html [ Slow ]
crbug.com/874695 virtual/scroll_customization/fast/scroll-behavior/overscroll-behavior.html [ Slow ] crbug.com/874695 virtual/scroll_customization/fast/scroll-behavior/overscroll-behavior.html [ Slow ]
crbug.com/874695 virtual/stable/http/tests/navigation/new-window-redirect-history.html [ Slow ] crbug.com/874695 virtual/stable/http/tests/navigation/new-window-redirect-history.html [ Slow ]
crbug.com/874695 virtual/stable/http/tests/navigation/slowmetaredirect-basic.html [ Slow ] crbug.com/874695 virtual/stable/http/tests/navigation/slowmetaredirect-basic.html [ Slow ]
...@@ -628,7 +625,6 @@ crbug.com/893015 [ Linux ] virtual/streaming-preload/http/tests/fetch/chromium/r ...@@ -628,7 +625,6 @@ crbug.com/893015 [ Linux ] virtual/streaming-preload/http/tests/fetch/chromium/r
crbug.com/914981 [ Mac ] media/controls/overflow-menu-pointer-selection.html [ Slow ] crbug.com/914981 [ Mac ] media/controls/overflow-menu-pointer-selection.html [ Slow ]
crbug.com/914981 [ Mac ] virtual/audio-service/media/controls/overflow-menu-pointer-selection.html [ Slow ] crbug.com/914981 [ Mac ] virtual/audio-service/media/controls/overflow-menu-pointer-selection.html [ Slow ]
crbug.com/914981 [ Mac ] virtual/mouseevent_fractional/fast/events/no-fake-mousemove.html [ Slow ]
crbug.com/914981 [ Mac ] fast/events/no-fake-mousemove.html [ Slow ] crbug.com/914981 [ Mac ] fast/events/no-fake-mousemove.html [ Slow ]
crbug.com/951895 [ Mac Debug ] transforms/2d/transform-2d.html [ Slow ] crbug.com/951895 [ Mac Debug ] transforms/2d/transform-2d.html [ Slow ]
......
...@@ -293,11 +293,6 @@ ...@@ -293,11 +293,6 @@
"bases": ["external/wpt/network-error-logging"], "bases": ["external/wpt/network-error-logging"],
"args": ["--enable-features=Reporting,NetworkErrorLogging"] "args": ["--enable-features=Reporting,NetworkErrorLogging"]
}, },
{
"prefix": "mouseevent_fractional",
"bases": ["fast/events"],
"args": ["--enable-blink-features=FractionalMouseEvent"]
},
{ {
"prefix": "compositor_threaded_scrollbar_scrolling", "prefix": "compositor_threaded_scrollbar_scrolling",
"bases": ["fast/scrolling/scrollbars", "bases": ["fast/scrolling/scrollbars",
......
This tests that DOMKeyboardEvents are created correctly in the JavaScript API.
keydown - key: Tab@DOM_KEY_LOCATION_STANDARD (keyCode/charCode: 9/0) modifiers: false,false,false,false
keyup - key: Tab@DOM_KEY_LOCATION_STANDARD (keyCode/charCode: 9/0) modifiers: false,false,true,false
This tests window.event was kept the same when nested event handling was called. You should see 'PASS' if the test passes.
PASS
This suite runs the tests in fast/events with
# --enable-blink-features=FractionalMouseEvent
This tests that focus() and sequential focus navigation work on empty anchors.
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
PASS document.activeElement is emptyAnchor1
PASS document.activeElement is emptyAnchor2
PASS successfullyParsed is true
TEST COMPLETE
This test ensures beforeunload event fires exactly once in a subframe even if the frame was adopted to a frame that appears later in the tree.
PASS: fired on parent
PASS: fired on a
PASS: fired on adoptee
adopting
adopted
PASS: fired on b
DONE
Detaching a frame in beforeunload event handler should not crash.
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
PASS if no crash
PASS successfullyParsed is true
TEST COMPLETE
This test ensures navigation is forbidden while beforeunload event is being fired. You should see PASS 1/2 and PASS 2/2 below:
PASS 1/2
--------
Frame: '<!--framePath //<!--frame0-->-->'
--------
PASS: 2/2
This tests beforeunload event in subframes. You should see PASS below:
PASS
--------
Frame: '<!--framePath //<!--frame0-->-->'
--------
Child loaded.
This test ensures setting location.href with javascript scheme properly executes the script even while beforeunload event is being fired. You should see PASS 1/2 and PASS 2/2 below:
PASS
This test ensures beforeunload event does not fire for subframes that has been removed from the DOM within a beforeunload event handler. Also ensures the event doesn't fire for subframes added within a beforeunload event handler. The latter behavior matches MSIE.
PASS: fired on parent
PASS: fired on a
PASS: fired on c
DONE
Tests that an exception is thrown when the value returned in the beforeunload callback cannot be converted to a String
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
PASS Exception was thrown
PASS testMessage is "Uncaught Exception in toString()"
PASS successfullyParsed is true
TEST COMPLETE
This test ensures beforeunload event fires in all subframes when a parent frame is navigated. You should see PASS 1/2 and PASS 2/2 below:
PASS 1/2
--------
Frame: '<!--framePath //<!--frame0-->-->'
--------
PASS: 2/2
Test that click events are fired for a slider when the range of values is dense enough that the thumb element is repositioned under the cursor on mouse press.
PASS successfullyParsed is true
TEST COMPLETE
PASS clickCount is 3
To manually test, press your browser shortcut for copy and then for paste. Several lines that say 'PASS' should appear below.
Copy handler:
Legacy
DataTransferItemList
Paste handler:
Legacy
DataTransferItemList
Tests copy / paste and DataTransferItemList
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
Running test with Legacy copy handler and Legacy paste handler
PASS testDataTransfer.getData("custom-data") is "hello world"
PASS testDataTransfer.clearData(nonConvertibleToString) threw exception Exception in toString().
PASS testDataTransfer.getData("custom-data") is "hello world"
PASS testDataTransfer.types.length is 4
PASS testDataTransfer.types.indexOf("text/plain") >= 0 is true
PASS testDataTransfer.types.indexOf("text/uri-list") >= 0 is true
PASS testDataTransfer.types.indexOf("text/html") >= 0 is true
PASS testDataTransfer.types.indexOf("custom-data") >= 0 is true
PASS testDataTransfer.getData("text") is "sample"
PASS testDataTransfer.getData("url") is "http://www.google.com/"
PASS testDataTransfer.getData("text/html") is "<em>Markup</em>"
PASS testDataTransfer.getData("custom-data") is "hello world"
Running test with Legacy copy handler and DataTransferItemList paste handler
PASS testDataTransfer.getData("custom-data") is "hello world"
PASS testDataTransfer.clearData(nonConvertibleToString) threw exception Exception in toString().
PASS testDataTransfer.getData("custom-data") is "hello world"
PASS testDataTransfer.items.length is 4
PASS JSON.stringify(expectedTypes) is JSON.stringify(types)
PASS testData is expectedTestData
PASS testData is expectedTestData
PASS testData is expectedTestData
PASS testData is expectedTestData
Running test with DataTransferItemList copy handler and Legacy paste handler
PASS testDataTransfer.items.item is undefined.
PASS testDataTransfer.types.length is 4
PASS testDataTransfer.types.indexOf("text/plain") >= 0 is true
PASS testDataTransfer.types.indexOf("text/uri-list") >= 0 is true
PASS testDataTransfer.types.indexOf("text/html") >= 0 is true
PASS testDataTransfer.types.indexOf("custom-data") >= 0 is true
PASS testDataTransfer.getData("text") is "sample"
PASS testDataTransfer.getData("url") is "http://www.google.com/"
PASS testDataTransfer.getData("text/html") is "<em>Markup</em>"
PASS testDataTransfer.getData("custom-data") is "hello world"
Running test with DataTransferItemList copy handler and DataTransferItemList paste handler
PASS testDataTransfer.items.item is undefined.
PASS testDataTransfer.items.length is 4
PASS JSON.stringify(expectedTypes) is JSON.stringify(types)
PASS testData is expectedTestData
PASS testData is expectedTestData
PASS testData is expectedTestData
PASS testData is expectedTestData
PASS successfullyParsed is true
TEST COMPLETE
Test that composition events should have a sourceCapabilities and its firesTouchEvents should always be false.
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
compositionstart
PASS event.sourceCapabilities is non-null.
PASS event.sourceCapabilities.firesTouchEvents is false
compositionupdate
PASS event.sourceCapabilities is non-null.
PASS event.sourceCapabilities.firesTouchEvents is false
compositionend
PASS event.sourceCapabilities is non-null.
PASS event.sourceCapabilities.firesTouchEvents is false
PASS successfullyParsed is true
TEST COMPLETE
This tests the constructor for the TrackEvent DOM class.
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
*** No initializer passed ***
PASS new TrackEvent('TrackEvent').bubbles is false
PASS new TrackEvent('TrackEvent').cancelable is false
PASS new TrackEvent('TrackEvent').track is null
*** Bubbles and cancelable true, track is missing ***
PASS new TrackEvent('TrackEvent', { bubbles: true, cancelable: true }).bubbles is true
PASS new TrackEvent('TrackEvent', { bubbles: true, cancelable: true }).cancelable is true
PASS new TrackEvent('TrackEvent', { bubbles: true, cancelable: true }).track is null
*** Bubbles and cancelable true, invalid track ***
PASS new TrackEvent('TrackEvent', { bubbles: true, cancelable: true, track: HTMLTrackElement }).bubbles threw exception TypeError: Failed to construct 'TrackEvent': The provided value is not of type '(VideoTrack or AudioTrack or TextTrack)'.
PASS new TrackEvent('TrackEvent', { bubbles: true, cancelable: true, track: HTMLTrackElement }).cancelable threw exception TypeError: Failed to construct 'TrackEvent': The provided value is not of type '(VideoTrack or AudioTrack or TextTrack)'.
PASS new TrackEvent('TrackEvent', { bubbles: true, cancelable: true, track: HTMLTrackElement }).track threw exception TypeError: Failed to construct 'TrackEvent': The provided value is not of type '(VideoTrack or AudioTrack or TextTrack)'.
*** Initialize 'track' with a invalid values ***
PASS new TrackEvent('TrackEvent', { track: 10 }).track threw exception TypeError: Failed to construct 'TrackEvent': The provided value is not of type '(VideoTrack or AudioTrack or TextTrack)'.
PASS new TrackEvent('TrackEvent', { track: 'string' }).track threw exception TypeError: Failed to construct 'TrackEvent': The provided value is not of type '(VideoTrack or AudioTrack or TextTrack)'.
PASS new TrackEvent('TrackEvent', { track: emptyObject }).track threw exception TypeError: Failed to construct 'TrackEvent': The provided value is not of type '(VideoTrack or AudioTrack or TextTrack)'.
PASS new TrackEvent('TrackEvent', { track: document }).track threw exception TypeError: Failed to construct 'TrackEvent': The provided value is not of type '(VideoTrack or AudioTrack or TextTrack)'.
*** Bubbles and cancelable true, valid track ***
PASS new TrackEvent('TrackEvent', { bubbles: true, cancelable: true, track: trackElement.track }).bubbles is true
PASS new TrackEvent('TrackEvent', { bubbles: true, cancelable: true, track: trackElement.track }).cancelable is true
PASS new TrackEvent('TrackEvent', { track: trackElement.track }).track is trackElement.track
*** Initialize 'track' with valid track object ***
PASS new TrackEvent('TrackEvent', { track: trackElement.track }).track is trackElement.track
PASS successfullyParsed is true
TEST COMPLETE
This tests that context menu events are sent to the correct frame when a page is scrolled. To test manually, scroll the page so that the top of the iframe is flush with the top of the web page area, then right-click just below the iframe. You should get a context menu that does not contain any mention of frames.
PASS: main document received a context menu event
Absolute
Relative
Fixed
x x
Table Content
In Columns
Transformed
In RTL overflow
PASS: event at (109, 57) hit absolute at offset (19, 22)
PASS: event at (161, 13) hit relative at offset (21, 18)
PASS: event at (40, 297) hit table-content at offset (5, 8)
FAIL: event at (122, 407) expected to hit transformed at (8, 5) but hit transformed at (7.713230133056641, 5.262882232666016)
PASS: event at (573, 480) hit inside-overflow at offset (2, 9)
FAIL: event at (707, 174) expected to hit in-columns at (87, 13) but hit in-columns at (87.34375, 13)
PASS: event at (241, 67) hit fixed at offset (31, 7)
PASS: event at (244, 102) hit fixed at offset (34, 42)
PASS: event at (388, 88) hit fixed at offset (178, 28)
To manually test, drag 'Drag Me' to 'Drop Here' and drop. Several lines that say 'PASS' should appear below.
Drag Me
Drop Here
Drag handler:
Legacy
DataTransferItemList
Drop handler:
Legacy
DataTransferItemList
Tests drag'n drop and well as DataTransferItemList
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
Running test with Legacy drag handler and Legacy drop handler
PASS testDataTransfer.types.length is 4
PASS testDataTransfer.types.indexOf("text/plain") >= 0 is true
PASS testDataTransfer.types.indexOf("text/uri-list") >= 0 is true
PASS testDataTransfer.types.indexOf("text/html") >= 0 is true
PASS testDataTransfer.types.indexOf("custom-data") >= 0 is true
PASS testDataTransfer.getData("text") is "sample"
PASS testDataTransfer.getData("url") is "http://www.google.com/"
PASS testDataTransfer.getData("text/html") is "<em>Markup</em>"
PASS testDataTransfer.getData("custom-data") is "hello world"
Running test with Legacy drag handler and DataTransferItemList drop handler
PASS testDataTransfer.items.length is 4
PASS testDataTransfer.items.add("test", "text/plain") is null
PASS testDataTransfer.items.length is 4
PASS JSON.stringify(expectedTypes) is JSON.stringify(types)
PASS testData is expectedTestData
PASS testData is expectedTestData
PASS testData is expectedTestData
PASS testData is expectedTestData
Running test with DataTransferItemList drag handler and Legacy drop handler
PASS testDataTransfer.items.add() threw exception TypeError: Failed to execute 'add' on 'DataTransferItemList': 1 argument required, but only 0 present..
PASS testDataTransfer.items.add(undefined) threw exception TypeError: Failed to execute 'add' on 'DataTransferItemList': parameter 1 is not of type 'File'..
PASS testDataTransfer.items.add("sample") threw exception TypeError: Failed to execute 'add' on 'DataTransferItemList': parameter 1 is not of type 'File'..
PASS testDataTransfer.items.add(null) threw exception TypeError: Failed to execute 'add' on 'DataTransferItemList': parameter 1 is not of type 'File'..
PASS testItem.kind is "string"
PASS testItem.type is "text/plain"
PASS testItem.kind is "string"
PASS testItem.type is "text/uri-list"
PASS testItem.kind is "string"
PASS testItem.type is "text/html"
PASS testItem.kind is "string"
PASS testItem.type is "custom-data"
PASS testDataTransfer.types.length is 4
PASS testDataTransfer.types.indexOf("text/plain") >= 0 is true
PASS testDataTransfer.types.indexOf("text/uri-list") >= 0 is true
PASS testDataTransfer.types.indexOf("text/html") >= 0 is true
PASS testDataTransfer.types.indexOf("custom-data") >= 0 is true
PASS testDataTransfer.getData("text") is "sample"
PASS testDataTransfer.getData("url") is "http://www.google.com/"
PASS testDataTransfer.getData("text/html") is "<em>Markup</em>"
PASS testDataTransfer.getData("custom-data") is "hello world"
Running test with DataTransferItemList drag handler and DataTransferItemList drop handler
PASS testDataTransfer.items.add() threw exception TypeError: Failed to execute 'add' on 'DataTransferItemList': 1 argument required, but only 0 present..
PASS testDataTransfer.items.add(undefined) threw exception TypeError: Failed to execute 'add' on 'DataTransferItemList': parameter 1 is not of type 'File'..
PASS testDataTransfer.items.add("sample") threw exception TypeError: Failed to execute 'add' on 'DataTransferItemList': parameter 1 is not of type 'File'..
PASS testDataTransfer.items.add(null) threw exception TypeError: Failed to execute 'add' on 'DataTransferItemList': parameter 1 is not of type 'File'..
PASS testItem.kind is "string"
PASS testItem.type is "text/plain"
PASS testItem.kind is "string"
PASS testItem.type is "text/uri-list"
PASS testItem.kind is "string"
PASS testItem.type is "text/html"
PASS testItem.kind is "string"
PASS testItem.type is "custom-data"
PASS testDataTransfer.items.length is 4
PASS testDataTransfer.items.add("test", "text/plain") is null
PASS testDataTransfer.items.length is 4
PASS JSON.stringify(expectedTypes) is JSON.stringify(types)
PASS testData is expectedTestData
PASS testData is expectedTestData
PASS testData is expectedTestData
PASS testData is expectedTestData
PASS successfullyParsed is true
TEST COMPLETE
Filename being dragged: onload-image.png
This test requires DumpRenderTree. To test manually, drag the image to the desktop. It should receive the name "onload-image.png".
Non-editable area
Editable area
This tests that images are properly left selected or unselected when an image drag is started. Only the image in the editable area should be selected when an image drag is started.
Starting test...
0 range(s) selected
Dragging image in non-editable area...
0 range(s) selected
Dragging image in editable area...
1 range(s) selected
imageTwo is selected
Tests dragging an SVG image. Test passes if the test does not crash.
Success - drag entered
Tests that the onchange event can be set on any element with an attribute.
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
PASS input.onchange fired.
PASS form.onchange fired.
PASS div.onchange fired.
PASS successfullyParsed is true
TEST COMPLETE
This test can be used to verify that a mousewheel event is fired when wheeling over the subframe but not dispatched to the parent frame.
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
PASS successfullyParsed is true
TEST COMPLETE
PASS received mousewheel event.
This test can be used to verify that a mousemove event is fired when moving the mouse cursor over an element in a subframe.
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
PASS successfullyParsed is true
TEST COMPLETE
PASS received mousemove event.
TEST COMPLETE
This tests that calling input-method functions sends Composition Events and Text Events introduced in DOM Level 3. To test manually, enable an IME, input CJK characters, and see this page doesn't show 'FAIL' lines.
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
PASS event.type is "compositionstart"
PASS event.data is ""
PASS event.type is "compositionupdate"
PASS event.data is "1"
PASS event.type is "compositionupdate"
PASS event.data is "2"
PASS event.type is "compositionupdate"
PASS event.data is "3"
PASS event.type is "compositionupdate"
PASS event.data is "4"
PASS event.type is "textInput"
PASS event.data is "4"
PASS event.type is "compositionend"
PASS event.data is "4"
PASS event.type is "compositionstart"
PASS event.data is ""
PASS event.type is "compositionupdate"
PASS event.data is "5"
PASS event.type is "compositionupdate"
PASS event.data is "6"
PASS event.type is "compositionupdate"
PASS event.data is "7"
PASS event.type is "compositionupdate"
PASS event.data is ""
PASS event.type is "textInput"
PASS event.data is ""
PASS event.type is "compositionend"
PASS event.data is ""
PASS event.type is "textInput"
PASS event.data is "8"
PASS event.type is "compositionstart"
PASS event.data is ""
PASS event.type is "compositionupdate"
PASS event.data is "9"
PASS event.type is "compositionend"
PASS event.data is "9"
PASS event.type is "compositionstart"
PASS event.data is "have"
PASS event.type is "compositionupdate"
PASS event.data is "lost"
PASS test.value is "I lost a pen"
PASS event.type is "compositionupdate"
PASS event.data is "made"
PASS event.type is "textInput"
PASS event.data is "made"
PASS event.type is "compositionend"
PASS event.data is "made"
PASS test.value is "I made a pen"
PASS successfullyParsed is true
TEST COMPLETE
This tests that dispatching a keyboard event created via javascript does not crash.
PASSED
This tests that DOMKeyboardEvents are created correctly in the JavaScript API.
keydown - key: Tab@DOM_KEY_LOCATION_STANDARD (keyCode/charCode: 9/0) modifiers: false,false,false,false
keyup - key: Tab@DOM_KEY_LOCATION_STANDARD (keyCode/charCode: 9/0) modifiers: false,false,true,false
To test manually, press keys and compare results to other browsers.
target - type - ctrlKey,altKey,shiftKey,metaKey - key - keyCode - charCode
Space:
INPUT - keydown - false,false,false,false - - 32 - 0
INPUT - keypress - false,false,false,false - - 32 - 32
INPUT - keyup - false,false,false,false - - 32 - 0
INPUT - click
Enter:
INPUT - keydown - false,false,false,false -Enter- 13 - 0
INPUT - keypress - false,false,false,false -Enter- 13 - 13
INPUT - click
INPUT - keyup - false,false,false,false -Enter- 13 - 0
A:
INPUT - keydown - false,false,true,false -A- 65 - 0
INPUT - keypress - false,false,true,false -A- 65 - 65
INPUT - keyup - false,false,true,false -A- 65 - 0
This tests that keydown events aren't sent to the main frame for command key presses that occur when a subframe is first responder. To run it manually, click inside the subframe, type a few characters, then do Command-A to Select All. Only the subframe should report a keydown event.
keydown in subframe: [object KeyboardEvent]
keydown in subframe: [object KeyboardEvent]
This sentence should not end with a period
This test verifies the keycodes sent when we press function keys.
Type=keydown,keyCode=112,ctrlKey=false,shiftKey=false,altKey=false,metaKey=false
Type=keyup,keyCode=112,ctrlKey=false,shiftKey=false,altKey=false,metaKey=false
Type=keydown,keyCode=113,ctrlKey=false,shiftKey=false,altKey=false,metaKey=false
Type=keyup,keyCode=113,ctrlKey=false,shiftKey=false,altKey=false,metaKey=false
Type=keydown,keyCode=114,ctrlKey=false,shiftKey=false,altKey=false,metaKey=false
Type=keyup,keyCode=114,ctrlKey=false,shiftKey=false,altKey=false,metaKey=false
Type=keydown,keyCode=115,ctrlKey=false,shiftKey=false,altKey=false,metaKey=false
Type=keyup,keyCode=115,ctrlKey=false,shiftKey=false,altKey=false,metaKey=false
Type=keydown,keyCode=116,ctrlKey=false,shiftKey=false,altKey=false,metaKey=false
Type=keyup,keyCode=116,ctrlKey=false,shiftKey=false,altKey=false,metaKey=false
Type=keydown,keyCode=117,ctrlKey=false,shiftKey=false,altKey=false,metaKey=false
Type=keyup,keyCode=117,ctrlKey=false,shiftKey=false,altKey=false,metaKey=false
Type=keydown,keyCode=118,ctrlKey=false,shiftKey=false,altKey=false,metaKey=false
Type=keyup,keyCode=118,ctrlKey=false,shiftKey=false,altKey=false,metaKey=false
Type=keydown,keyCode=119,ctrlKey=false,shiftKey=false,altKey=false,metaKey=false
Type=keyup,keyCode=119,ctrlKey=false,shiftKey=false,altKey=false,metaKey=false
Type=keydown,keyCode=120,ctrlKey=false,shiftKey=false,altKey=false,metaKey=false
Type=keyup,keyCode=120,ctrlKey=false,shiftKey=false,altKey=false,metaKey=false
Type=keydown,keyCode=121,ctrlKey=false,shiftKey=false,altKey=false,metaKey=false
Type=keyup,keyCode=121,ctrlKey=false,shiftKey=false,altKey=false,metaKey=false
Type=keydown,keyCode=122,ctrlKey=false,shiftKey=false,altKey=false,metaKey=false
Type=keyup,keyCode=122,ctrlKey=false,shiftKey=false,altKey=false,metaKey=false
Type=keydown,keyCode=123,ctrlKey=false,shiftKey=false,altKey=false,metaKey=false
Type=keyup,keyCode=123,ctrlKey=false,shiftKey=false,altKey=false,metaKey=false
Tests that WebKit does not crash when a frame is removed during keydown event processing. To test manually, press any letter key. The iframe below should disappear and Safari should not crash.
Test cross-frame MessagePort communication.
Should be a series of SUCCESS messages, followed with DONE.
Simple exchange: SUCCESS
Simple exchange: SUCCESS
Posted port: SUCCESS
Posted port: SUCCESS
Event Listener: SUCCESS
Event Listener: SUCCESS
Closed port: SUCCESS
Closed port: SUCCESS
MessageEvent.cancelable defaults to false: PASS
MessageEvent.cancelable defaults to false: PASS
DONE
Test that messaging an inactive frameless document works as expected.
Didn't crash, freeze or respond: SUCCESS
PASS successfullyParsed is true
TEST COMPLETE
Starting Autoscroll test on iframe
PASSED : the autoscroll has worked !
Test for bug 336373.
To test manually, hold the middle mouse button on the box with scrollbars and scroll by dragging the mouse outside the bounds of the box. If the bug occurs once the cursor leaves the bounds of the box it will remain stuck in the panning state.
Click me
PASS successfullyParsed is true
TEST COMPLETE
Starting Autoscroll test on iframe
PASSED : the autoscroll has worked !
Test for bug 336373.
To test manually, hold the middle mouse button on the box with scrollbars and scroll by dragging the mouse outside the bounds of the box. If the bug occurs once the cursor leaves the bounds of the box it will remain stuck in the panning state.
Click me
<!-- This is a replacement test for fast/event/clientXY-in-zoom-and-scroll.html with fractional coordinates-->
<script src="../../../../resources/testharness.js"></script>
<script src="../../../../resources/testharnessreport.js"></script>
<style>
#pusher {
width: 1000px;
height: 1000px;
outline: 1px solid black;
}
</style>
<div id="console"></div>
<div id="testArea">
<div id="pusher">This box is here to create scrollbars.</div>
</div>
<script>
const floatPrecision = 0.00001;
const leftButton = 0;
function sendMouseDownAt(x, y) {
return new Promise(function(resolve, reject) {
if (window.chrome && chrome.gpuBenchmarking) {
var pointerActions =
[{source: "mouse",
actions: [
{ name: "pointerMove", x: x, y: y},
{ name: "pointerDown", x: x, y: y, button: leftButton},
{ name: "pointerUp" },
]}];
chrome.gpuBenchmarking.pointerActionSequence(pointerActions, resolve);
}
else {
reject();
}
});
}
function mouseEventHandler(event) {
event_log.push(event);
event.preventDefault();
}
events = ["mousemove", "mousedown", "mouseup", "click"]
for (var i = 0; i < events.length; i++) {
window.addEventListener(events[i], mouseEventHandler);
};
promise_test(async () => {
event_log = [];
await sendMouseDownAt(100, 100);
assert_true(event_log.length > 0);
for (var i = 0; i < event_log.length; i++) {
assert_equals(event_log[i].clientX, 100);
assert_equals(event_log[i].clientY, 100);
assert_equals(event_log[i].pageX, 100);
assert_equals(event_log[i].pageY, 100);
}
}, 'Default');
promise_test(async () => {
eventSender.setPageZoomFactor(1.2);
event_log = [];
await sendMouseDownAt(100, 100);
assert_true(event_log.length > 0);
for (var i = 0; i < event_log.length; i++) {
assert_approx_equals(event_log[i].clientX, 83.33333, floatPrecision);
assert_approx_equals(event_log[i].clientY, 83.33333, floatPrecision);
assert_approx_equals(event_log[i].pageX, 83.33333, floatPrecision);
assert_approx_equals(event_log[i].pageY, 83.33333, floatPrecision);
eventSender.setPageZoomFactor(1.0)
}
}, 'Zoomed');
promise_test(async () => {
event_log = [];
window.scrollTo(50, 50);
await sendMouseDownAt(100, 100);
assert_true(event_log.length > 0);
for (var i = 0; i < event_log.length; i++) {
assert_equals(event_log[i].clientX, 100);
assert_equals(event_log[i].clientY, 100);
assert_equals(event_log[i].pageX, 150);
assert_equals(event_log[i].pageY, 150);
window.scrollTo(0, 0);
}
}, 'Scrolled');
promise_test(async () => {
event_log = [];
eventSender.setPageZoomFactor(1.2);
window.scrollTo(50, 50);
await sendMouseDownAt(100, 100);
assert_true(event_log.length > 0);
for (var i = 0; i < event_log.length; i++) {
assert_approx_equals(event_log[i].clientX, 83.33333, floatPrecision);
assert_approx_equals(event_log[i].clientY, 83.33333, floatPrecision);
assert_approx_equals(event_log[i].pageX, 133.33333, floatPrecision);
assert_approx_equals(event_log[i].pageY, 133.33333, floatPrecision);
eventSender.setPageZoomFactor(1.0)
window.scrollTo(0, 0);
}
}, 'Zoomed and scrolled');
</script>
\ No newline at end of file
Test that a cursor change that occurs due only to a style change correctly considers iframes.
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
Mouse moved to cursor changing div
PASS internals.getCurrentCursorInfo() is "type=Hand hotSpot=0,0"
Changing cursor style
PASS internals.getCurrentCursorInfo() is "type=Wait hotSpot=0,0"
Now move mouse onto iframe above cursor changing div
PASS document.elementFromPoint(100, y) is frame
PASS document.elementsFromPoint(100, y).indexOf(container) > 0 is true
PASS internals.cursorUpdatePending is false
PASS internals.getCurrentCursorInfo() is "type=IBeam hotSpot=0,0"
Changing cursor style of the background should not affect the cursor as it sits over the iframe
PASS internals.getCurrentCursorInfo() is "type=IBeam hotSpot=0,0"
PASS successfullyParsed is true
TEST COMPLETE
This tests that dragging from an element that returns false from its mousedown handler will not let the subsequent mousemove events be captured by the containing frame.
Drag started
Received mouse move
Received mouseup event
PASS!
span
PASS simulateElementClick(testElement, [100, 100, 200, 200]); is '100, 100, 200, 200'
PASS simulateElementClick(spanElement, [16, 10, 16, 10]); is '16, 10, 16, 10'
PASS simulateElementClick(inputElement, [39, 9, 95, 10]); is '39, 9, 95, 10'
PASS successfullyParsed is true
TEST COMPLETE
<!-- This is a replacement test for fast/event/clientXY-in-zoom-and-scroll.html with fractional coordinates-->
<script src="../../../../resources/testharness.js"></script>
<script src="../../../../resources/testharnessreport.js"></script>
<style>
#pusher {
width: 1000px;
height: 1000px;
outline: 1px solid black;
}
</style>
<div id="console"></div>
<div id="testArea">
<div id="pusher">This box is here to create scrollbars.</div>
</div>
<script>
const floatPrecision = 0.00001;
const rightButton = 2;
function sendMouseDownAt(x, y) {
return new Promise(function(resolve, reject) {
if (window.chrome && chrome.gpuBenchmarking) {
var pointerActions =
[{source: "mouse",
actions: [
{ name: "pointerMove", x: x, y: y},
{ name: "pointerDown", x: x, y: y, button: rightButton},
{ name: "pointerUp" },
]}];
chrome.gpuBenchmarking.pointerActionSequence(pointerActions, resolve);
}
else {
reject();
}
});
}
function mouseEventHandler(event) {
event_log.push(event);
event.preventDefault();
}
events = ["mousemove", "mousedown", "mouseup", "contextmenu", "auxclick"]
for (var i = 0; i < events.length; i++) {
window.addEventListener(events[i], mouseEventHandler);
};
promise_test(async () => {
event_log = [];
await sendMouseDownAt(100, 100);
assert_true(event_log.length > 0);
for (var i = 0; i < event_log.length; i++) {
assert_equals(event_log[i].clientX, 100);
assert_equals(event_log[i].clientY, 100);
assert_equals(event_log[i].pageX, 100);
assert_equals(event_log[i].pageY, 100);
}
}, 'Default');
promise_test(async () => {
eventSender.setPageZoomFactor(1.2);
event_log = [];
await sendMouseDownAt(100, 100);
assert_true(event_log.length > 0);
for (var i = 0; i < event_log.length; i++) {
assert_approx_equals(event_log[i].clientX, 83.33333, floatPrecision);
assert_approx_equals(event_log[i].clientY, 83.33333, floatPrecision);
assert_approx_equals(event_log[i].pageX, 83.33333, floatPrecision);
assert_approx_equals(event_log[i].pageY, 83.33333, floatPrecision);
eventSender.setPageZoomFactor(1.0)
}
}, 'Zoomed');
promise_test(async () => {
event_log = [];
window.scrollTo(50, 50);
await sendMouseDownAt(100, 100);
assert_true(event_log.length > 0);
for (var i = 0; i < event_log.length; i++) {
assert_equals(event_log[i].clientX, 100);
assert_equals(event_log[i].clientY, 100);
assert_equals(event_log[i].pageX, 150);
assert_equals(event_log[i].pageY, 150);
window.scrollTo(0, 0);
}
}, 'Scrolled');
promise_test(async () => {
event_log = [];
eventSender.setPageZoomFactor(1.2);
window.scrollTo(50, 50);
await sendMouseDownAt(100, 100);
assert_true(event_log.length > 0);
for (var i = 0; i < event_log.length; i++) {
assert_approx_equals(event_log[i].clientX, 83.33333, floatPrecision);
assert_approx_equals(event_log[i].clientY, 83.33333, floatPrecision);
assert_approx_equals(event_log[i].pageX, 133.33333, floatPrecision);
assert_approx_equals(event_log[i].pageY, 133.33333, floatPrecision);
eventSender.setPageZoomFactor(1.0)
window.scrollTo(0, 0);
}
}, 'Zoomed and scrolled');
</script>
\ No newline at end of file
This tests that clicking on a scrollbar in a frame does not clear selections in the frame.
Selection: This
is
text
to
force
a
vertical
scrollbar
to
appear.
TOP
Tests that hover is lost from iframe when the mouse is moved from iframe to the element that stacked up on iframe
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
PASS successfullyParsed is true
TEST COMPLETE
PASS hoverBgColor is "rgb(255, 0, 0)"
PASS events[0] is "mouseenter"
PASS targetIds[0] is "target"
PASS events[1] is "mousemove"
PASS targetIds[1] is "target"
PASS bgColor is "rgb(255, 255, 0)"
FAIL events[2] should be mouseleave. Was mouseout.
PASS targetIds[2] is "target"
FAIL events[3] should be mouseout. Was mouseleave.
PASS targetIds[3] is "target"
Tests for bugs 3439, 5764, 7701 - Mouse events vs. DOM manipulation.
Move the mouse pointer from left to right:
1              
1              
2
3
4
5
Log
mouseover on t1_1
mouseout on t1_1
mouseover on t1_2
mouseout on t1_2
mouseover on t2_1
mouseout on t2_1
mouseover on t2_2
mouseout on t2_2
mouseover on t3_1
mouseover on t3_2
mouseout on t3_2
mouseover on t4_1
mouseover on t4_2
mouseout on t4_2
mouseover on t5_1
mouseover on t5_2
mouseout on t5_2
mouseover on frame6
mouseover on t6
mouseout on t6
mouseout on frame6
This test verifies that a button that receives a mouse down event does not receive a corresponding mouse up event when the mouse up happens outside the button.
If the test passes, you'll see a PASS message below.
To run this test in Safari:
Mouse down inside the button.
Move the mouse outside the button.
Mouse up.
PASS: mouse up event did not fire
This tests window.event was kept the same when nested event handling was called. You should see 'PASS' if the test passes.
PASS
Absolute position
Relative position
Fixed position
First Second
This cell has borderTopExtra
Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.
Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.
In columns
Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
Div with transform
Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.
In RTL overflow
Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
PASS: event hit abs-box at offset (17, 22)
PASS: event hit rel-box at offset (22, 24)
PASS: event hit fixed-box at offset (10, 10)
PASS: event hit with-bordertopextra at offset (4, 4)
FAIL: event expected to hit in-columns at (35, 5) but hit in-columns at (34.8125, 5)
PASS: event hit inside-overflow at offset (7, 6)
FAIL: event expected to hit transformed at (11, 16) but hit transformed at (10.535758972167969, 15.941521644592285)
This test verifies that the ENTER key fires the change event.
PASS: change event fired.
This test verifies that updating the slider for an input element with type=range fires a change event.
PASS successfullyParsed is true
TEST COMPLETE
PASS Change event fired.
PASS slider.value is "0"
This test verifies that the ENTER key fires the change event.
PASS: change event fired.
This test verifies that the ENTER key fires the change event.
PASS: change event fired.
This test verifies that the load event fires after a document.close, even if the document contains no subresources. See bug 13241.
PASS: onload fired
This test verifies that the load event doesn't fire until subresource content has loaded, even if you manually call document.close beforehand. See bug 13241.
dimensions before onload (should be { 0 x 0 }, otherwise the test will falsely pass): { 0 x 0 }
dimensions during onload (should be { 215 x 174 }, otherwise onload fired too early): { 215 x 174 }
This page tests whether the form 'submit' event bubbles to containing elements. If it passes, you'll see 'PASS' messages below.
PASS: containing element div2 caught submit event
PASS: containing element div1 caught submit event
This test checks that Page Visibility state events are propagated to child frames.
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
Main Page:
PASS document.visibilityState is "visible"
PASS document.hidden is false
Child Frame:
PASS childFrame.contentDocument.visibilityState is "visible"
PASS childFrame.contentDocument.hidden is false
Main Page:
PASS document.visibilityState is "hidden"
PASS document.hidden is true
Child Frame:
PASS childFrame.contentDocument.visibilityState is "hidden"
PASS childFrame.contentDocument.hidden is true
Main Page:
PASS document.visibilityState is "visible"
PASS document.hidden is false
Child Frame:
PASS childFrame.contentDocument.visibilityState is "visible"
PASS childFrame.contentDocument.hidden is false
PASS successfullyParsed is true
TEST COMPLETE
Test pageshow/pagehide event behavior in subframes.
***Original load - onload and pageshow events should fire for subframes, and then for main frame***
Subsubframe window.onload
Subsubframe window.onpageshow, target = [object HTMLDocument], persisted = false
Subframe window.onload
Subframe window.onpageshow, target = [object HTMLDocument], persisted = false
Main frame window.onload
Main frame window.onpageshow, target = [object HTMLDocument], persisted = false
***Navigating bottom-level subframe, onpagehide events should fire for subsubframe***
Subsubframe window.onpagehide, target = [object HTMLDocument], persisted = false
Subsubframe window.onunload
Subsubframe window.onload
Subsubframe window.onpageshow, target = [object HTMLDocument], persisted = false
***Navigating mid-level subframe, onpagehide events should fire for both subframes***
Subframe window.onpagehide, target = [object HTMLDocument], persisted = false
Subframe window.onunload
Subsubframe window.onpagehide, target = [object HTMLDocument], persisted = false
Subsubframe window.onunload
Subframe window.onload
Subframe window.onpageshow, target = [object HTMLDocument], persisted = false
***Done***
Test that we don't create a new user gesture indicator every time an event is passed to an iframe.
To run, click on the iframe. The test passes, if only one window is opened in response to the click.
PASSED
CONSOLE MESSAGE: line 1: PASSED
abcd
efgh
If the pop-up was not blocked then there will be an PASS message. Otherwise, the test fails.
This test checks that programmaticly changing the checked state of a checkbox does not fire the "change" event (but user action like calling "click" does).
PASS: got exactly one change event.
This test ensures Blink does fire a click event on the parent element of a clicked text node even when the text node has been removed in mouseup event.
PASS
Test that resize events are fired at requestAnimationFrame timing
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
PASS resizeEventCount is 1
PASS successfullyParsed is true
TEST COMPLETE
Tests that page shouldn't scroll when you hit space key on input field and 'textInput' event was canceled.
PASS document.scrollingElement.scrollTop became 0
PASS successfullyParsed is true
TEST COMPLETE
This test verifies that the correct sequence of keyboard events is generated for a keypress for certain special keys. To test manually, press keys and compare results to other browsers.
target - type - ctrlKey,altKey,shiftKey,metaKey - key - keyCode - charCode
Ampersand:
INPUT - keydown - false,false,true,false -7- 55 - 0. Value: "".
INPUT - keypress - false,false,true,false -7- 55 - 55. Value: "".
INPUT - textInput - 7. Value: "".
INPUT - keyup - false,false,true,false -7- 55 - 0. Value: "7".
Backspace:
INPUT - keydown - false,false,false,false -Backspace- 8 - 0. Value: "7".
INPUT - keyup - false,false,false,false -Backspace- 8 - 0. Value: "".
Percent:
INPUT - keydown - false,false,true,false -5- 53 - 0. Value: "".
INPUT - keypress - false,false,true,false -5- 53 - 53. Value: "".
INPUT - textInput - 5. Value: "".
INPUT - keyup - false,false,true,false -5- 53 - 0. Value: "5".
Backspace:
INPUT - keydown - false,false,false,false -Backspace- 8 - 0. Value: "5".
INPUT - keyup - false,false,false,false -Backspace- 8 - 0. Value: "".
Left parenthesis:
INPUT - keydown - false,false,true,false -9- 57 - 0. Value: "".
INPUT - keypress - false,false,true,false -9- 57 - 57. Value: "".
INPUT - textInput - 9. Value: "".
INPUT - keyup - false,false,true,false -9- 57 - 0. Value: "9".
Backspace:
INPUT - keydown - false,false,false,false -Backspace- 8 - 0. Value: "9".
INPUT - keyup - false,false,false,false -Backspace- 8 - 0. Value: "".
Right parenthesis:
INPUT - keydown - false,false,true,false -0- 48 - 0. Value: "".
INPUT - keypress - false,false,true,false -0- 48 - 48. Value: "".
INPUT - textInput - 0. Value: "".
INPUT - keyup - false,false,true,false -0- 48 - 0. Value: "0".
Backspace:
INPUT - keydown - false,false,false,false -Backspace- 8 - 0. Value: "0".
INPUT - keyup - false,false,false,false -Backspace- 8 - 0. Value: "".
Print screen:
INPUT - keydown - false,false,false,false -PrintScreen- 44 - 0. Value: "".
INPUT - keyup - false,false,false,false -PrintScreen- 44 - 0. Value: "".
Test passes if there is no crash
Google (tabindex 5)
Yahoo (tabindex 2)
Google (tabindex 4)
Yahoo (tabindex 6)
Verify that in the absence of any reason to adjust into an iframe, taps are handle in the frame matching the center point of the tap. bug 401504
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
Sending GestureTap on top of iframe
PASS sawClick is false
Sending GestureTap above iframe
Received click on DIV#container
PASS sawClick is true
Sending GestureTap to the left of iframe
Received click on DIV#container
PASS sawClick is true
Sending GestureTap to the right of iframe
Received click on DIV#container
PASS sawClick is true
Sending GestureTap below iframe
Received click on DIV#container
PASS sawClick is true
PASS successfullyParsed is true
TEST COMPLETE
PASS successfullyParsed is true
TEST COMPLETE
This test checks long press behavior inside an iframe when both touch drag/drop and touch editing are enabled.
1. Check that long press on a draggable element starts drag.
2. Check that long press on non-draggable text selects the text.
3. Check that long press on selected text starts drag.
Testing
PASS
FAIL
PASS successfullyParsed is true
TEST COMPLETE
This test checks that a long press gesture on a draggable element in an iframe starts a drag/drop session.
Testing
FAIL
PASS
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment