Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(488)

Unified Diff: third_party/WebKit/Source/core/layout/LayoutView.cpp

Issue 1834263002: Round visual rects when crossing frame boundaries. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/core/layout/LayoutView.cpp
diff --git a/third_party/WebKit/Source/core/layout/LayoutView.cpp b/third_party/WebKit/Source/core/layout/LayoutView.cpp
index b49d539afca42b34114e18eefccf3d55200781ed..de4197ade8f4e2e7ebbb163e8d9001ddbab1963a 100644
--- a/third_party/WebKit/Source/core/layout/LayoutView.cpp
+++ b/third_party/WebKit/Source/core/layout/LayoutView.cpp
@@ -529,6 +529,10 @@ bool LayoutView::mapToVisibleRectInAncestorSpace(const LayoutBoxModelObject* anc
// Adjust for scroll offset of the view.
rect.moveBy(-viewRectangle.location());
}
+ // Frames are painted at rounded-int position. Since we cannot efficiently compute the subpixel offset
+ // of painting at this point in a a bottom-up walk, round to the enclosing int rect, which will enclose
+ // the actual visible rect.
+ rect = LayoutRect(enclosingIntRect(rect));
// Adjust for frame border.
rect.move(obj->contentBoxOffset());

Powered by Google App Engine
This is Rietveld 408576698