Bug 89556 - Touch adjustment does not target shadow DOM elements
Summary: Touch adjustment does not target shadow DOM elements
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: UI Events (show other bugs)
Version: 412.x
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Allan Sandfeld Jensen
URL:
Keywords:
: 89674 (view as bug list)
Depends on:
Blocks:
 
Reported: 2012-06-20 02:49 PDT by Allan Sandfeld Jensen
Modified: 2012-06-26 17:41 PDT (History)
9 users (show)

See Also:


Attachments
Patch (1.75 KB, patch)
2012-06-20 02:54 PDT, Allan Sandfeld Jensen
no flags Details | Formatted Diff | Diff
Archive of layout-test-results from ec2-cr-linux-04 (682.62 KB, application/zip)
2012-06-20 04:30 PDT, WebKit Review Bot
no flags Details
Patch (9.02 KB, patch)
2012-06-20 06:18 PDT, Allan Sandfeld Jensen
no flags Details | Formatted Diff | Diff
Patch (9.10 KB, patch)
2012-06-20 07:06 PDT, Allan Sandfeld Jensen
no flags Details | Formatted Diff | Diff
Patch (9.63 KB, patch)
2012-06-26 06:58 PDT, Kevin Ellis
no flags Details | Formatted Diff | Diff
Patch (9.92 KB, patch)
2012-06-26 07:49 PDT, Kevin Ellis
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Allan Sandfeld Jensen 2012-06-20 02:49:36 PDT
EventHandler::bestClickableNodeForTouchPoint() is currently ignoring shadow DOM elements, which means that it is currently not possible to use the controls of media-elements for instance.
Comment 1 Allan Sandfeld Jensen 2012-06-20 02:54:00 PDT
Created attachment 148529 [details]
Patch
Comment 2 WebKit Review Bot 2012-06-20 04:30:30 PDT
Comment on attachment 148529 [details]
Patch

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

New failing tests:
touchadjustment/html-label.html
Comment 3 WebKit Review Bot 2012-06-20 04:30:33 PDT
Created attachment 148538 [details]
Archive of layout-test-results from ec2-cr-linux-04

The attached test failures were seen while running run-webkit-tests on the chromium-ews.
Bot: ec2-cr-linux-04  Port: <class 'webkitpy.common.config.ports.ChromiumXVFBPort'>  Platform: Linux-2.6.35-28-virtual-x86_64-with-Ubuntu-10.10-maverick
Comment 4 Allan Sandfeld Jensen 2012-06-20 06:18:58 PDT
Created attachment 148547 [details]
Patch
Comment 5 Kenneth Rohde Christiansen 2012-06-20 06:38:58 PDT
Comment on attachment 148547 [details]
Patch

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

LGTM

> LayoutTests/touchadjustment/media-element.html:28
> +    function testRoundTouch(x, y, radius)
> +    {

I think we normally keep the { on the same line in JS
Comment 6 Build Bot 2012-06-20 06:40:05 PDT
Comment on attachment 148547 [details]
Patch

Attachment 148547 [details] did not pass win-ews (win):
Output: http://queues.webkit.org/results/12996218
Comment 7 Build Bot 2012-06-20 06:59:10 PDT
Comment on attachment 148547 [details]
Patch

Attachment 148547 [details] did not pass mac-ews (mac):
Output: http://queues.webkit.org/results/13001200
Comment 8 Allan Sandfeld Jensen 2012-06-20 07:06:07 PDT
Created attachment 148557 [details]
Patch
Comment 9 Antonio Gomes 2012-06-20 07:45:06 PDT
Allan, does it make use of bug #80847 ?
Comment 10 Allan Sandfeld Jensen 2012-06-20 07:52:59 PDT
(In reply to comment #9)
> Allan, does it make use of bug #80847 ?

Yes, I think that is what enables the fix to be this simple.
Comment 11 Allan Sandfeld Jensen 2012-06-22 02:49:08 PDT
*** Bug 89674 has been marked as a duplicate of this bug. ***
Comment 12 Allan Sandfeld Jensen 2012-06-22 02:56:19 PDT
(In reply to comment #11)
> *** Bug 89674 has been marked as a duplicate of this bug. ***

The test-case in the patch posted in bug #89674 looks like a more safe way to test shadow-dom that what I do.
Comment 13 Antonio Gomes 2012-06-22 11:34:20 PDT
Comment on attachment 148557 [details]
Patch

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

Code looks ok. One question: does it overlap with bug 89674?

> LayoutTests/touchadjustment/media-element.html:33
> +        var adjustedNode = internals.touchNodeAdjustedToBestClickableNode(x, y, width, height, document);

should/could we unify internals::touchNodeAdjustedToBestClickableNode and Internals::nodeFromRect ?

> LayoutTests/touchadjustment/media-element.html:40
> +        adjustedNode = testRoundTouch(120, 480, 120);

can not you do something like

 26       var playCoords;
 27       try {
 28           playCoords = mediaControlsButtonCoordinates(video, "play-button");
 29       } catch (exception) {
 30           failTest(exception.description);
 31           return;
?
Comment 14 Kevin Ellis 2012-06-26 06:58:37 PDT
Created attachment 149527 [details]
Patch
Comment 15 Kevin Ellis 2012-06-26 07:01:59 PDT
*** Bug 89674 has been marked as a duplicate of this bug. ***
Comment 16 Kevin Ellis 2012-06-26 07:49:02 PDT
Created attachment 149531 [details]
Patch
Comment 17 Allan Sandfeld Jensen 2012-06-26 10:37:48 PDT
Comment on attachment 148557 [details]
Patch

Newer patch available.
Comment 18 WebKit Review Bot 2012-06-26 17:41:43 PDT
Comment on attachment 149531 [details]
Patch

Clearing flags on attachment: 149531

Committed r121305: <http://trac.webkit.org/changeset/121305>
Comment 19 WebKit Review Bot 2012-06-26 17:41:49 PDT
All reviewed patches have been landed.  Closing bug.