Clicking edges of media control buttons changes visual state of button (pressed)...
authorcommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sun, 16 Jul 2017 22:23:52 +0000 (22:23 +0000)
committercommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sun, 16 Jul 2017 22:23:52 +0000 (22:23 +0000)
commit246139674f460eefb15646e90fa9f422fa954061
tree537814f5c5e0c1df1e434aa7ec73c0945979c810
parent3d27d99a3d2697311a1fb0d67cf3508ad047741d
Clicking edges of media control buttons changes visual state of button (pressed) but doesn't execute action
https://bugs.webkit.org/show_bug.cgi?id=174565
<rdar://problem/33294833>

Patch by Antoine Quint <graouts@apple.com> on 2017-07-16
Reviewed by Dean Jackson.

Source/WebCore:

WebCore doesn't dispatch a "click" event to a parent element when a child that was the original target when
the "mousedown" occured is no longer hit-testing at the location where the mouse pointer is at when the "mouseup"
occurs (see webkit.org/b/174564). Since button icons, which are a <picture> element that is a child of the
<button> element for media controls buttons, shrink to 89% of their size when the ":active" pseudo-class matches,
clicking on the edges of the media controls buttons would not trigger the expected action.

Test: media/modern-media-controls/button/button-click-on-edges.html

* Modules/modern-media-controls/controls/button.css:
(button > picture):

LayoutTests:

Add a new test where we click on the edge of a button and check that we trigger the Button's
UI delegate. This test fails prior to this patch.

* media/modern-media-controls/button/button-click-on-edges-expected.txt: Added.
* media/modern-media-controls/button/button-click-on-edges.html: Added.
* platform/ios-simulator/TestExpectations:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@219549 268f45cc-cd09-0410-ab3c-d52691b4dbfc
LayoutTests/ChangeLog
LayoutTests/media/modern-media-controls/button/button-click-on-edges-expected.txt [new file with mode: 0644]
LayoutTests/media/modern-media-controls/button/button-click-on-edges.html [new file with mode: 0644]
LayoutTests/platform/ios-simulator/TestExpectations
Source/WebCore/ChangeLog
Source/WebCore/Modules/modern-media-controls/controls/button.css