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

Side by Side Diff: third_party/WebKit/Source/core/paint/PrePaintTreeWalk.cpp

Issue 2852573002: Rename InvalidatePaintIfNeeded to drop deprecated IfNeeded suffix. (Closed)
Patch Set: Created 3 years, 7 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 unified diff | Download patch
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "core/paint/PrePaintTreeWalk.h" 5 #include "core/paint/PrePaintTreeWalk.h"
6 6
7 #include "core/dom/DocumentLifecycle.h" 7 #include "core/dom/DocumentLifecycle.h"
8 #include "core/frame/FrameView.h" 8 #include "core/frame/FrameView.h"
9 #include "core/frame/LocalFrame.h" 9 #include "core/frame/LocalFrame.h"
10 #include "core/layout/LayoutMultiColumnSpannerPlaceholder.h" 10 #include "core/layout/LayoutMultiColumnSpannerPlaceholder.h"
(...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after
83 bool needs_tree_builder_context_update = 83 bool needs_tree_builder_context_update =
84 this->NeedsTreeBuilderContextUpdate(frame_view, parent_context); 84 this->NeedsTreeBuilderContextUpdate(frame_view, parent_context);
85 PrePaintTreeWalkContext context(parent_context, 85 PrePaintTreeWalkContext context(parent_context,
86 needs_tree_builder_context_update); 86 needs_tree_builder_context_update);
87 // ancestorOverflowLayer does not cross frame boundaries. 87 // ancestorOverflowLayer does not cross frame boundaries.
88 context.ancestor_overflow_paint_layer = nullptr; 88 context.ancestor_overflow_paint_layer = nullptr;
89 if (context.tree_builder_context) { 89 if (context.tree_builder_context) {
90 property_tree_builder_.UpdateProperties(frame_view, 90 property_tree_builder_.UpdateProperties(frame_view,
91 *context.tree_builder_context); 91 *context.tree_builder_context);
92 } 92 }
93 paint_invalidator_.InvalidatePaintIfNeeded(frame_view, 93 paint_invalidator_.InvalidatePaint(frame_view,
94 context.paint_invalidator_context); 94 context.paint_invalidator_context);
95 95
96 if (LayoutView* view = frame_view.GetLayoutView()) { 96 if (LayoutView* view = frame_view.GetLayoutView()) {
97 Walk(*view, context); 97 Walk(*view, context);
98 #if DCHECK_IS_ON() 98 #if DCHECK_IS_ON()
99 view->AssertSubtreeClearedPaintInvalidationFlags(); 99 view->AssertSubtreeClearedPaintInvalidationFlags();
100 #endif 100 #endif
101 } 101 }
102 frame_view.ClearNeedsPaintPropertyUpdate(); 102 frame_view.ClearNeedsPaintPropertyUpdate();
103 } 103 }
104 104
(...skipping 174 matching lines...) Expand 10 before | Expand all | Expand 10 after
279 // This must happen before updatePropertiesForSelf, because the latter reads 279 // This must happen before updatePropertiesForSelf, because the latter reads
280 // some of the state computed here. 280 // some of the state computed here.
281 UpdateAuxiliaryObjectProperties(object, context); 281 UpdateAuxiliaryObjectProperties(object, context);
282 282
283 if (context.tree_builder_context) { 283 if (context.tree_builder_context) {
284 DCHECK(context.tree_builder_context); 284 DCHECK(context.tree_builder_context);
285 property_tree_builder_.UpdatePropertiesForSelf( 285 property_tree_builder_.UpdatePropertiesForSelf(
286 object, *context.tree_builder_context); 286 object, *context.tree_builder_context);
287 } 287 }
288 288
289 paint_invalidator_.InvalidatePaintIfNeeded(object, 289 paint_invalidator_.InvalidatePaint(object, context.paint_invalidator_context);
290 context.paint_invalidator_context);
291 290
292 if (context.tree_builder_context) { 291 if (context.tree_builder_context) {
293 property_tree_builder_.UpdatePropertiesForChildren( 292 property_tree_builder_.UpdatePropertiesForChildren(
294 object, *context.tree_builder_context); 293 object, *context.tree_builder_context);
295 InvalidatePaintLayerOptimizationsIfNeeded(object, context); 294 InvalidatePaintLayerOptimizationsIfNeeded(object, context);
296 } 295 }
297 296
298 for (const LayoutObject* child = object.SlowFirstChild(); child; 297 for (const LayoutObject* child = object.SlowFirstChild(); child;
299 child = child->NextSibling()) { 298 child = child->NextSibling()) {
300 if (child->IsLayoutMultiColumnSpannerPlaceholder()) { 299 if (child->IsLayoutMultiColumnSpannerPlaceholder()) {
(...skipping 16 matching lines...) Expand all
317 } 316 }
318 Walk(*frame_view, context); 317 Walk(*frame_view, context);
319 } 318 }
320 // TODO(pdr): Investigate RemoteFrameView (crbug.com/579281). 319 // TODO(pdr): Investigate RemoteFrameView (crbug.com/579281).
321 } 320 }
322 321
323 object.GetMutableForPainting().ClearPaintFlags(); 322 object.GetMutableForPainting().ClearPaintFlags();
324 } 323 }
325 324
326 } // namespace blink 325 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698