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

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

Issue 2768453003: Put SVGResourceContainer subtypes into their own property trees. (Closed)
Patch Set: none Created 3 years, 8 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 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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/ObjectPaintInvalidator.h" 5 #include "core/paint/ObjectPaintInvalidator.h"
6 6
7 #include "core/frame/FrameView.h" 7 #include "core/frame/FrameView.h"
8 #include "core/frame/LocalFrame.h" 8 #include "core/frame/LocalFrame.h"
9 #include "core/layout/LayoutView.h" 9 #include "core/layout/LayoutView.h"
10 #include "core/layout/api/LayoutPartItem.h" 10 #include "core/layout/api/LayoutPartItem.h"
(...skipping 474 matching lines...) Expand 10 before | Expand all | Expand 10 after
485 // container vs scrolling contents). 485 // container vs scrolling contents).
486 return !m_context.paintInvalidationContainer->usesCompositedScrolling(); 486 return !m_context.paintInvalidationContainer->usesCompositedScrolling();
487 } 487 }
488 488
489 void ObjectPaintInvalidatorWithContext::invalidatePaintRectangleWithContext( 489 void ObjectPaintInvalidatorWithContext::invalidatePaintRectangleWithContext(
490 const LayoutRect& rect, 490 const LayoutRect& rect,
491 PaintInvalidationReason reason) { 491 PaintInvalidationReason reason) {
492 if (rect.isEmpty()) 492 if (rect.isEmpty())
493 return; 493 return;
494 494
495 if (m_context.forcedSubtreeInvalidationFlags &
496 PaintInvalidatorContext::ForcedSubtreeNoRasterInvalidation)
497 return;
498
495 // If the parent has fully invalidated and its visual rect covers this object 499 // If the parent has fully invalidated and its visual rect covers this object
496 // on the same backing, skip the invalidation. 500 // on the same backing, skip the invalidation.
497 if (parentFullyInvalidatedOnSameBacking() && 501 if (parentFullyInvalidatedOnSameBacking() &&
498 (m_context.parentContext->oldVisualRect.contains(rect) || 502 (m_context.parentContext->oldVisualRect.contains(rect) ||
499 m_object.parent()->visualRect().contains(rect))) 503 m_object.parent()->visualRect().contains(rect)))
500 return; 504 return;
501 505
502 invalidatePaintUsingContainer(*m_context.paintInvalidationContainer, rect, 506 invalidatePaintUsingContainer(*m_context.paintInvalidationContainer, rect,
503 reason); 507 reason);
504 } 508 }
(...skipping 141 matching lines...) Expand 10 before | Expand all | Expand 10 after
646 650
647 m_context.paintingLayer->setNeedsRepaint(); 651 m_context.paintingLayer->setNeedsRepaint();
648 m_object.invalidateDisplayItemClients(reason); 652 m_object.invalidateDisplayItemClients(reason);
649 return reason; 653 return reason;
650 } 654 }
651 655
652 DisablePaintInvalidationStateAsserts::DisablePaintInvalidationStateAsserts() 656 DisablePaintInvalidationStateAsserts::DisablePaintInvalidationStateAsserts()
653 : m_disabler(&gDisablePaintInvalidationStateAsserts, true) {} 657 : m_disabler(&gDisablePaintInvalidationStateAsserts, true) {}
654 658
655 } // namespace blink 659 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698