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

Unified Diff: third_party/WebKit/Source/core/paint/PaintLayerScrollableArea.cpp

Issue 2417683002: Disable scroll anchoring when in printing mode (Closed)
Patch Set: Add comment Created 4 years, 2 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/paint/PaintLayerScrollableArea.cpp
diff --git a/third_party/WebKit/Source/core/paint/PaintLayerScrollableArea.cpp b/third_party/WebKit/Source/core/paint/PaintLayerScrollableArea.cpp
index 9767274a2a6a1a2784f48e208702e6774aae7ad4..35c3536af0c484dc8130a4fef181442d0a5b5333 100644
--- a/third_party/WebKit/Source/core/paint/PaintLayerScrollableArea.cpp
+++ b/third_party/WebKit/Source/core/paint/PaintLayerScrollableArea.cpp
@@ -830,7 +830,8 @@ void PaintLayerScrollableArea::clampScrollOffsetsAfterLayout() {
bool PaintLayerScrollableArea::shouldPerformScrollAnchoring() const {
return RuntimeEnabledFeatures::scrollAnchoringEnabled() &&
m_scrollAnchor.hasScroller() &&
- layoutBox()->style()->overflowAnchor() != AnchorNone;
+ layoutBox()->style()->overflowAnchor() != AnchorNone &&
+ !box().document().finishingOrIsPrinting();
}
ScrollBehavior PaintLayerScrollableArea::scrollBehaviorStyle() const {
« no previous file with comments | « third_party/WebKit/Source/core/layout/ScrollAnchorTest.cpp ('k') | third_party/WebKit/Source/core/paint/TextPainterTest.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698