Chromium Code Reviews| OLD | NEW |
|---|---|
| 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 709 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 720 FloatSize viewportSizeForViewportUnits() const; | 720 FloatSize viewportSizeForViewportUnits() const; |
| 721 | 721 |
| 722 ScrollAnchor* scrollAnchor() override { return &m_scrollAnchor; } | 722 ScrollAnchor* scrollAnchor() override { return &m_scrollAnchor; } |
| 723 void clearScrollAnchor(); | 723 void clearScrollAnchor(); |
| 724 bool shouldPerformScrollAnchoring() const override; | 724 bool shouldPerformScrollAnchoring() const override; |
| 725 | 725 |
| 726 // For PaintInvalidator temporarily. TODO(wangxianzhu): Move into | 726 // For PaintInvalidator temporarily. TODO(wangxianzhu): Move into |
| 727 // PaintInvalidator. | 727 // PaintInvalidator. |
| 728 void invalidatePaintIfNeeded(const PaintInvalidationState&); | 728 void invalidatePaintIfNeeded(const PaintInvalidationState&); |
| 729 | 729 |
| 730 bool disableScrollAnchoringForPrinting() { | |
| 731 return m_disableScrollAnchoringForPrinting; | |
| 732 } | |
| 733 void setDisableScrollAnchoringForPrinting(bool value) { | |
| 734 m_disableScrollAnchoringForPrinting = value; | |
| 735 } | |
| 736 | |
| 730 // Only for SPv2. | 737 // Only for SPv2. |
| 731 std::unique_ptr<JSONObject> compositedLayersAsJSON(LayerTreeFlags); | 738 std::unique_ptr<JSONObject> compositedLayersAsJSON(LayerTreeFlags); |
| 732 | 739 |
| 733 protected: | 740 protected: |
| 734 // Scroll the content via the compositor. | 741 // Scroll the content via the compositor. |
| 735 bool scrollContentsFastPath(const IntSize& scrollDelta); | 742 bool scrollContentsFastPath(const IntSize& scrollDelta); |
| 736 | 743 |
| 737 // Scroll the content by invalidating everything. | 744 // Scroll the content by invalidating everything. |
| 738 void scrollContentsSlowPath(); | 745 void scrollContentsSlowPath(); |
| 739 | 746 |
| (...skipping 311 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 1051 RefPtr<ClipPaintPropertyNode> m_contentClip; | 1058 RefPtr<ClipPaintPropertyNode> m_contentClip; |
| 1052 // The property tree state that should be used for painting contents. These | 1059 // The property tree state that should be used for painting contents. These |
| 1053 // properties are either created by this FrameView or are inherited from | 1060 // properties are either created by this FrameView or are inherited from |
| 1054 // an ancestor. | 1061 // an ancestor. |
| 1055 std::unique_ptr<PropertyTreeState> m_totalPropertyTreeStateForContents; | 1062 std::unique_ptr<PropertyTreeState> m_totalPropertyTreeStateForContents; |
| 1056 | 1063 |
| 1057 // This is set on the local root frame view only. | 1064 // This is set on the local root frame view only. |
| 1058 DocumentLifecycle::LifecycleState m_currentUpdateLifecyclePhasesTargetState; | 1065 DocumentLifecycle::LifecycleState m_currentUpdateLifecyclePhasesTargetState; |
| 1059 | 1066 |
| 1060 ScrollAnchor m_scrollAnchor; | 1067 ScrollAnchor m_scrollAnchor; |
| 1068 // This is set when we're in printing mode. We can't reuse the m_printing bit | |
| 1069 // from blink::Document because it's reset before the set of layouts caused | |
|
skobes
2016/10/12 22:40:31
This seems wrong. Isn't Document::m_printing clea
ymalik
2016/10/13 13:48:04
Not quite. Document::m_printing is cleared from Lo
skobes
2016/10/13 16:24:00
Ah, I suspect LocalFrame::setPrinting does a layou
ymalik
2016/10/14 16:30:56
Yes an enum is cleaner in this case. It also allow
| |
| 1070 // by printing. | |
| 1071 bool m_disableScrollAnchoringForPrinting; | |
| 1061 | 1072 |
| 1062 bool m_needsScrollbarsUpdate; | 1073 bool m_needsScrollbarsUpdate; |
| 1063 bool m_suppressAdjustViewSize; | 1074 bool m_suppressAdjustViewSize; |
| 1064 bool m_allowsLayoutInvalidationAfterLayoutClean; | 1075 bool m_allowsLayoutInvalidationAfterLayoutClean; |
| 1065 | 1076 |
| 1066 // For testing. | 1077 // For testing. |
| 1067 struct ObjectPaintInvalidation { | 1078 struct ObjectPaintInvalidation { |
| 1068 String name; | 1079 String name; |
| 1069 PaintInvalidationReason reason; | 1080 PaintInvalidationReason reason; |
| 1070 }; | 1081 }; |
| (...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 1107 widget.isFrameView()); | 1118 widget.isFrameView()); |
| 1108 DEFINE_TYPE_CASTS(FrameView, | 1119 DEFINE_TYPE_CASTS(FrameView, |
| 1109 ScrollableArea, | 1120 ScrollableArea, |
| 1110 scrollableArea, | 1121 scrollableArea, |
| 1111 scrollableArea->isFrameView(), | 1122 scrollableArea->isFrameView(), |
| 1112 scrollableArea.isFrameView()); | 1123 scrollableArea.isFrameView()); |
| 1113 | 1124 |
| 1114 } // namespace blink | 1125 } // namespace blink |
| 1115 | 1126 |
| 1116 #endif // FrameView_h | 1127 #endif // FrameView_h |
| OLD | NEW |