Bug 170520 - Simple line layout: Hittest always returns the first renderer in the block.
Summary: Simple line layout: Hittest always returns the first renderer in the block.
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Layout and Rendering (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: zalan
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-04-05 14:08 PDT by zalan
Modified: 2017-04-06 13:03 PDT (History)
5 users (show)

See Also:


Attachments
Patch (11.29 KB, patch)
2017-04-05 14:44 PDT, zalan
no flags Details | Formatted Diff | Diff
Patch (10.76 KB, patch)
2017-04-06 09:48 PDT, zalan
no flags Details | Formatted Diff | Diff
Patch (10.70 KB, patch)
2017-04-06 12:23 PDT, zalan
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description zalan 2017-04-05 14:08:06 PDT
SSIA.

somewhat related: rdar://problem/30979175
Comment 1 zalan 2017-04-05 14:44:28 PDT
Created attachment 306319 [details]
Patch
Comment 2 Antti Koivisto 2017-04-06 08:23:07 PDT
Comment on attachment 306319 [details]
Patch

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

> Source/WebCore/rendering/SimpleLineLayoutResolver.h:134
> +        struct LineOverlap {
> +            FloatRect rect;
> +            const RenderObject& renderer;
> +        };

It would be good idea to add a FIXME here explaining how this is wrong (there can be multiple renderers per line).

> Source/WebCore/rendering/SimpleLineLayoutResolver.h:142
> -        const FloatRect operator*() const;
> +        const LineOverlap operator*() const;

Maybe there could be a separate lineOverlap() function and keep the operator* as-is? Or do all clients need the renderer too?
Comment 3 zalan 2017-04-06 09:48:30 PDT
Created attachment 306396 [details]
Patch
Comment 4 WebKit Commit Bot 2017-04-06 12:02:16 PDT
Comment on attachment 306396 [details]
Patch

Rejecting attachment 306396 [details] from commit-queue.

Failed to run "['/Volumes/Data/EWS/WebKit/Tools/Scripts/webkit-patch', '--status-host=webkit-queues.webkit.org', '--bot-id=webkit-cq-01', 'validate-changelog', '--check-oops', '--non-interactive', 306396, '--port=mac']" exit_code: 1 cwd: /Volumes/Data/EWS/WebKit

ChangeLog entry in LayoutTests/ChangeLog contains OOPS!.

Full output: http://webkit-queues.webkit.org/results/3485805
Comment 5 zalan 2017-04-06 12:23:21 PDT
Created attachment 306408 [details]
Patch
Comment 6 WebKit Commit Bot 2017-04-06 13:03:58 PDT
Comment on attachment 306408 [details]
Patch

Clearing flags on attachment: 306408

Committed r215054: <http://trac.webkit.org/changeset/215054>
Comment 7 WebKit Commit Bot 2017-04-06 13:03:59 PDT
All reviewed patches have been landed.  Closing bug.