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

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

Issue 2480863002: DCHECK that paint properties are never null (Closed)
Patch Set: dcheckmate Created 4 years, 1 month 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
« no previous file with comments | « no previous file | third_party/WebKit/Source/platform/graphics/paint/CompositingRecorder.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/core/paint/FramePainter.cpp
diff --git a/third_party/WebKit/Source/core/paint/FramePainter.cpp b/third_party/WebKit/Source/core/paint/FramePainter.cpp
index db2a9b975f08db308575a617b25e11539aaafe84..6fcc221b604d7627daad3a87fc16e5c0dcf569a8 100644
--- a/third_party/WebKit/Source/core/paint/FramePainter.cpp
+++ b/third_party/WebKit/Source/core/paint/FramePainter.cpp
@@ -94,11 +94,20 @@ void FramePainter::paint(GraphicsContext& context,
Optional<ScopedPaintChunkProperties> scopedPaintChunkProperties;
if (RuntimeEnabledFeatures::slimmingPaintV2Enabled()) {
- if (TransformPaintPropertyNode* transform =
- m_frameView->preTranslation()) {
+ if (const PropertyTreeState* contentsState =
+ m_frameView->totalPropertyTreeStateForContents()) {
+ // The scrollbar's property nodes are similar to the frame view's
+ // contents state but we want to exclude the content-specific
+ // properties. This prevents the scrollbars from scrolling, for example.
PaintChunkProperties properties(
context.getPaintController().currentPaintChunkProperties());
- properties.transform = transform;
+ properties.transform = m_frameView->preTranslation();
+ properties.clip = m_frameView->contentClip()->parent();
+ properties.effect = contentsState->effect();
+ auto* scrollBarScroll = contentsState->scroll();
+ if (m_frameView->scroll())
+ scrollBarScroll = m_frameView->scroll()->parent();
+ properties.scroll = scrollBarScroll;
scopedPaintChunkProperties.emplace(context.getPaintController(),
*frameView().layoutView(),
properties);
« no previous file with comments | « no previous file | third_party/WebKit/Source/platform/graphics/paint/CompositingRecorder.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698