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

Side by Side Diff: third_party/WebKit/Source/core/frame/FrameView.h

Issue 2583733003: Use LayoutObject::subtreeNeedsPaintPropertyUpdate for printing invalidation (Closed)
Patch Set: - Created 3 years, 12 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
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/frame/FrameView.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 Copyright (C) 1997 Martin Jones (mjones@kde.org) 2 Copyright (C) 1997 Martin Jones (mjones@kde.org)
3 (C) 1998 Waldo Bastian (bastian@kde.org) 3 (C) 1998 Waldo Bastian (bastian@kde.org)
4 (C) 1998, 1999 Torben Weis (weis@kde.org) 4 (C) 1998, 1999 Torben Weis (weis@kde.org)
5 (C) 1999 Lars Knoll (knoll@kde.org) 5 (C) 1999 Lars Knoll (knoll@kde.org)
6 (C) 1999 Antti Koivisto (koivisto@kde.org) 6 (C) 1999 Antti Koivisto (koivisto@kde.org)
7 Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009 Apple Inc. All rights 7 Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009 Apple Inc. All rights
8 reserved. 8 reserved.
9 9
10 This library is free software; you can redistribute it and/or 10 This library is free software; you can redistribute it and/or
(...skipping 738 matching lines...) Expand 10 before | Expand all | Expand 10 after
749 void setOnlyThisNeedsPaintPropertyUpdateForTesting() { 749 void setOnlyThisNeedsPaintPropertyUpdateForTesting() {
750 m_needsPaintPropertyUpdate = true; 750 m_needsPaintPropertyUpdate = true;
751 } 751 }
752 #endif 752 #endif
753 void clearNeedsPaintPropertyUpdate() { 753 void clearNeedsPaintPropertyUpdate() {
754 DCHECK_EQ(lifecycle().state(), DocumentLifecycle::InPrePaint); 754 DCHECK_EQ(lifecycle().state(), DocumentLifecycle::InPrePaint);
755 m_needsPaintPropertyUpdate = false; 755 m_needsPaintPropertyUpdate = false;
756 } 756 }
757 bool needsPaintPropertyUpdate() const { return m_needsPaintPropertyUpdate; } 757 bool needsPaintPropertyUpdate() const { return m_needsPaintPropertyUpdate; }
758 758
759 // Set when the whole frame subtree needs full paint invalidation and paint 759 // Set when the whole frame subtree needs full paint property update,
760 // property update, e.g. when beginning or finishing printing. 760 // e.g. when beginning or finishing printing.
761 void setShouldInvalidateAllPaintAndPaintProperties() { 761 void setSubtreeNeedsPaintPropertyUpdate();
762 m_shouldInvalidateAllPaintAndPaintProperties = true;
763 }
764 void clearShouldInvalidateAllPaintAndPaintProperties() {
765 m_shouldInvalidateAllPaintAndPaintProperties = true;
766 }
767 bool shouldInvalidateAllPaintAndPaintProperties() const {
768 return m_shouldInvalidateAllPaintAndPaintProperties;
769 }
770 762
771 // TODO(ojan): Merge this with IntersectionObserver once it lands. 763 // TODO(ojan): Merge this with IntersectionObserver once it lands.
772 IntRect computeVisibleArea(); 764 IntRect computeVisibleArea();
773 765
774 // Viewport size that should be used for viewport units (i.e. 'vh'/'vw'). 766 // Viewport size that should be used for viewport units (i.e. 'vh'/'vw').
775 FloatSize viewportSizeForViewportUnits() const; 767 FloatSize viewportSizeForViewportUnits() const;
776 768
777 ScrollAnchor* scrollAnchor() override { return &m_scrollAnchor; } 769 ScrollAnchor* scrollAnchor() override { return &m_scrollAnchor; }
778 void clearScrollAnchor(); 770 void clearScrollAnchor();
779 bool shouldPerformScrollAnchoring() const override; 771 bool shouldPerformScrollAnchoring() const override;
(...skipping 360 matching lines...) Expand 10 before | Expand all | Expand 10 after
1140 // TODO(trchen): This will not be needed once settings->rootLayerScrolls() is 1132 // TODO(trchen): This will not be needed once settings->rootLayerScrolls() is
1141 // enabled. 1133 // enabled.
1142 RefPtr<ClipPaintPropertyNode> m_contentClip; 1134 RefPtr<ClipPaintPropertyNode> m_contentClip;
1143 // The property tree state that should be used for painting contents. These 1135 // The property tree state that should be used for painting contents. These
1144 // properties are either created by this FrameView or are inherited from 1136 // properties are either created by this FrameView or are inherited from
1145 // an ancestor. 1137 // an ancestor.
1146 std::unique_ptr<PropertyTreeState> m_totalPropertyTreeStateForContents; 1138 std::unique_ptr<PropertyTreeState> m_totalPropertyTreeStateForContents;
1147 // Whether the paint properties need to be updated. For more details, see 1139 // Whether the paint properties need to be updated. For more details, see
1148 // FrameView::needsPaintPropertyUpdate(). 1140 // FrameView::needsPaintPropertyUpdate().
1149 bool m_needsPaintPropertyUpdate; 1141 bool m_needsPaintPropertyUpdate;
1150 bool m_shouldInvalidateAllPaintAndPaintProperties;
1151 1142
1152 // This is set on the local root frame view only. 1143 // This is set on the local root frame view only.
1153 DocumentLifecycle::LifecycleState m_currentUpdateLifecyclePhasesTargetState; 1144 DocumentLifecycle::LifecycleState m_currentUpdateLifecyclePhasesTargetState;
1154 1145
1155 ScrollAnchor m_scrollAnchor; 1146 ScrollAnchor m_scrollAnchor;
1156 using AnchoringAdjustmentQueue = 1147 using AnchoringAdjustmentQueue =
1157 HeapLinkedHashSet<WeakMember<ScrollableArea>>; 1148 HeapLinkedHashSet<WeakMember<ScrollableArea>>;
1158 AnchoringAdjustmentQueue m_anchoringAdjustmentQueue; 1149 AnchoringAdjustmentQueue m_anchoringAdjustmentQueue;
1159 1150
1160 // ScrollbarManager holds the Scrollbar instances. 1151 // ScrollbarManager holds the Scrollbar instances.
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after
1218 widget.isFrameView()); 1209 widget.isFrameView());
1219 DEFINE_TYPE_CASTS(FrameView, 1210 DEFINE_TYPE_CASTS(FrameView,
1220 ScrollableArea, 1211 ScrollableArea,
1221 scrollableArea, 1212 scrollableArea,
1222 scrollableArea->isFrameView(), 1213 scrollableArea->isFrameView(),
1223 scrollableArea.isFrameView()); 1214 scrollableArea.isFrameView());
1224 1215
1225 } // namespace blink 1216 } // namespace blink
1226 1217
1227 #endif // FrameView_h 1218 #endif // FrameView_h
OLDNEW
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/frame/FrameView.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698