[Webkit-unassigned] [Bug 162367] Add long press selection test

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Thu Sep 22 16:12:23 PDT 2016


https://bugs.webkit.org/show_bug.cgi?id=162367

--- Comment #11 from Simon Fraser (smfr) <simon.fraser at apple.com> ---
Comment on attachment 289614
  --> https://bugs.webkit.org/attachment.cgi?id=289614
Patch

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

> Tools/ChangeLog:14
> +        Add support to UIScriptController to synthesize long press events on iOS. This required adding long-press functionality to HIDEventGenerator.
> +
> +        HIDEventGenerator sends the touchDown, but must then send the touchUp with a dispatch_after (rather than sleeping, as we do for other events) in order for the gesture recognizers to correctly detect a long press.
> +
> +        Use the long press synthesis in a test that detects whether a long press gesture triggers text selection.
> +
> +        Fixed incorrect constants. NSTimeInterval is in seconds, original numbers were nanoseconds and typedefed to long without regard to the type differences. Redid constants to be the right value, and converted upon use.

You should hard wrap these lines to 80 chars or so. Look at the other entries for examples.

> LayoutTests/fast/events/touch/ios/long-press-to-select-text.html:33
> +                    var selection = document.getSelection().toString();

Variable would be better named as "selectionText" or "seletionAsString"

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.webkit.org/pipermail/webkit-unassigned/attachments/20160922/fd74b43c/attachment-0001.html>


More information about the webkit-unassigned mailing list