Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge r230088 - Web Automation: clipToViewport is ignored for element…
… screenshots https://bugs.webkit.org/show_bug.cgi?id=184158 <rdar://problem/39014307> Reviewed by Timothy Hatcher. In §19.2 Take Element Screenshot, step 5.2 says that we should clip the element screenshot rect with the visible viewport rect. We don't do that right now even though we pass over clipToViewport. * WebProcess/Automation/WebAutomationSessionProxy.cpp: (WebKit::snapshotRectForScreenshot): Clip the rect to viewport if needed. (WebKit::WebAutomationSessionProxy::takeScreenshot): This scrollIntoView is misplaced; by this point we have already done the math to figure out the screenshot rect. Move it before computing the rect.
- Loading branch information
1 parent
8e8df7a
commit cea5df2
Showing
2 changed files
with
32 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters