Bug 79117 - [chromium] Fix issues in visiblePositionForWindowPoint (offscreen points / iframes).
Summary: [chromium] Fix issues in visiblePositionForWindowPoint (offscreen points / if...
Alias: None
Product: WebKit
Classification: Unclassified
Component: New Bugs (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Oli Lan
Depends on:
Blocks: 66687
  Show dependency treegraph
Reported: 2012-02-21 08:46 PST by Oli Lan
Modified: 2019-05-02 16:25 PDT (History)
6 users (show)

See Also:

Patch (2.17 KB, patch)
2012-02-21 08:53 PST, Oli Lan
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Oli Lan 2012-02-21 08:46:35 PST
[chromium] Fix issues in visiblePositionForWindowPoint (offscreen points / iframes).
Comment 1 Oli Lan 2012-02-21 08:53:16 PST
Created attachment 127981 [details]
Comment 2 Eric Seidel (no email) 2012-05-21 15:05:59 PDT
Comment on attachment 127981 [details]

How do we test this?
Comment 3 Ryosuke Niwa 2012-07-13 15:36:53 PDT
Comment on attachment 127981 [details]

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

> Source/WebKit/chromium/ChangeLog:14
> +        1) If the point is off-screen, the visiblePosition is clipped to the screen.
> +           - The fix is to add HitTestRequest::IgnoreClipping.
> +
> +        2) The result is incorrect if the point is within an iframe.
> +           - This is because we are calling convertFromContainingWindow twice: once in windowToContents,
> +             and then explicitly as well.
> +           - This patch removes the explicit call to convertFromContainingWindow. 

We need tests for these two problems.

> Source/WebKit/chromium/ChangeLog:16
> +        Reviewed by NOBODY (OOPS!).

This line should appear before the long description.
Comment 4 Adam Barth 2012-07-27 01:43:44 PDT
Comment on attachment 127981 [details]

We really should write tests for this sort of patch.  I feel a bit like I'm encouraging bad behavior by approving this patch, but I also want you to encourage you to submit patches to WebKit.  On balance, I'm going to r+ this patch, but please include tests with future patches.  You should also feel encouraged to upload a followup patch that contains a patch.  If you're unsure how to write a test for this issue, I'm happy to help.
Comment 5 WebKit Review Bot 2012-07-27 02:36:40 PDT
Comment on attachment 127981 [details]

Clearing flags on attachment: 127981

Committed r123855: <http://trac.webkit.org/changeset/123855>
Comment 6 WebKit Review Bot 2012-07-27 02:36:44 PDT
All reviewed patches have been landed.  Closing bug.
Comment 7 Oli Lan 2012-07-27 02:38:50 PDT
Thanks Adam. I meant to come back to this to add tests but hadn't got round to it. I'll add tests for these cases in another patch.
Comment 8 Adam Barth 2012-07-27 02:41:06 PDT
Thanks.  I figured it just got lost in the shuffle.