Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 /* | 1 /* |
| 2 * Copyright (C) 2000 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 2000 Lars Knoll (knoll@kde.org) |
| 3 * (C) 2000 Antti Koivisto (koivisto@kde.org) | 3 * (C) 2000 Antti Koivisto (koivisto@kde.org) |
| 4 * (C) 2000 Dirk Mueller (mueller@kde.org) | 4 * (C) 2000 Dirk Mueller (mueller@kde.org) |
| 5 * (C) 2004 Allan Sandfeld Jensen (kde@carewolf.com) | 5 * (C) 2004 Allan Sandfeld Jensen (kde@carewolf.com) |
| 6 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2012 Apple Inc. All r ights reserved. | 6 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2012 Apple Inc. All r ights reserved. |
| 7 * Copyright (C) 2009 Google Inc. All rights reserved. | 7 * Copyright (C) 2009 Google Inc. All rights reserved. |
| 8 * | 8 * |
| 9 * This library is free software; you can redistribute it and/or | 9 * This library is free software; you can redistribute it and/or |
| 10 * modify it under the terms of the GNU Library General Public | 10 * modify it under the terms of the GNU Library General Public |
| (...skipping 1172 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 1183 | 1183 |
| 1184 // When this object is invalidated for paint, this method is called to inval idate any DisplayItemClients | 1184 // When this object is invalidated for paint, this method is called to inval idate any DisplayItemClients |
| 1185 // owned by this object, including the object itself, LayoutText/LayoutInlin e line boxes, etc., | 1185 // owned by this object, including the object itself, LayoutText/LayoutInlin e line boxes, etc., |
| 1186 // not including children which will be invalidated normally during invalida teTreeIfNeeded() and | 1186 // not including children which will be invalidated normally during invalida teTreeIfNeeded() and |
| 1187 // parts which are invalidated separately (e.g. scrollbars). | 1187 // parts which are invalidated separately (e.g. scrollbars). |
| 1188 virtual void invalidateDisplayItemClients(const LayoutBoxModelObject& paintI nvalidationContainer) const; | 1188 virtual void invalidateDisplayItemClients(const LayoutBoxModelObject& paintI nvalidationContainer) const; |
| 1189 | 1189 |
| 1190 void setIsSlowRepaintObject(bool); | 1190 void setIsSlowRepaintObject(bool); |
| 1191 | 1191 |
| 1192 private: | 1192 private: |
| 1193 // Adjusts a paint invalidation rect in the space of |m_previousPaintInvalid ationRect| and |m_previousPositionFromPaintInvalidationBacking| | |
| 1194 // to be in the space of the |paintInvalidationContainer|, | |
| 1195 // if needed. They can be different only if |paintInvalidationContainer| is a composited scroller. | |
| 1196 void adjustInvalidationRectForCompositedScrolling(LayoutRect&, const LayoutB oxModelObject& paintInvalidationContainer); | |
| 1197 | |
| 1193 void clearLayoutRootIfNeeded() const; | 1198 void clearLayoutRootIfNeeded() const; |
| 1194 | 1199 |
| 1195 bool isInert() const; | 1200 bool isInert() const; |
| 1196 | 1201 |
| 1197 void updateImage(StyleImage*, StyleImage*); | 1202 void updateImage(StyleImage*, StyleImage*); |
| 1198 | 1203 |
| 1199 void scheduleRelayout(); | 1204 void scheduleRelayout(); |
| 1200 | 1205 |
| 1201 void updateShapeImage(const ShapeValue*, const ShapeValue*); | 1206 void updateShapeImage(const ShapeValue*, const ShapeValue*); |
| 1202 void updateFillImages(const FillLayer* oldLayers, const FillLayer& newLayers ); | 1207 void updateFillImages(const FillLayer* oldLayers, const FillLayer& newLayers ); |
| (...skipping 216 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 1419 void setIsDragging(bool b) { m_bitfields.setIsDragging(b); } | 1424 void setIsDragging(bool b) { m_bitfields.setIsDragging(b); } |
| 1420 void setEverHadLayout(bool b) { m_bitfields.setEverHadLayout(b); } | 1425 void setEverHadLayout(bool b) { m_bitfields.setEverHadLayout(b); } |
| 1421 void setShouldInvalidateOverflowForPaint(bool b) { m_bitfields.setShouldInva lidateOverflowForPaint(b); } | 1426 void setShouldInvalidateOverflowForPaint(bool b) { m_bitfields.setShouldInva lidateOverflowForPaint(b); } |
| 1422 void setSelfNeedsOverflowRecalcAfterStyleChange(bool b) { m_bitfields.setSel fNeedsOverflowRecalcAfterStyleChange(b); } | 1427 void setSelfNeedsOverflowRecalcAfterStyleChange(bool b) { m_bitfields.setSel fNeedsOverflowRecalcAfterStyleChange(b); } |
| 1423 void setChildNeedsOverflowRecalcAfterStyleChange(bool b) { m_bitfields.setCh ildNeedsOverflowRecalcAfterStyleChange(b); } | 1428 void setChildNeedsOverflowRecalcAfterStyleChange(bool b) { m_bitfields.setCh ildNeedsOverflowRecalcAfterStyleChange(b); } |
| 1424 | 1429 |
| 1425 private: | 1430 private: |
| 1426 // Store state between styleWillChange and styleDidChange | 1431 // Store state between styleWillChange and styleDidChange |
| 1427 static bool s_affectsParentBlock; | 1432 static bool s_affectsParentBlock; |
| 1428 | 1433 |
| 1429 // This stores the paint invalidation rect from the previous frame. | 1434 // This stores the paint invalidation rect from the previous frame. This rec t does *not* account for composited scrolling. See |
|
skobes
2015/08/13 21:26:10
It's a little unclear what it means to "account fo
| |
| 1435 // adjustInvalidationRectForCompositedScrolling(). | |
| 1430 LayoutRect m_previousPaintInvalidationRect; | 1436 LayoutRect m_previousPaintInvalidationRect; |
| 1431 | 1437 |
| 1432 // This stores the position in the paint invalidation backing's coordinate. | 1438 // This stores the position in the paint invalidation backing's coordinate. |
| 1433 // It is used to detect layoutObject shifts that forces a full invalidation. | 1439 // It is used to detect layoutObject shifts that forces a full invalidation. |
| 1440 // This point does *not* account for composited scrolling. See adjustInvalid ationRectForCompositedScrolling(). | |
| 1434 LayoutPoint m_previousPositionFromPaintInvalidationBacking; | 1441 LayoutPoint m_previousPositionFromPaintInvalidationBacking; |
| 1435 }; | 1442 }; |
| 1436 | 1443 |
| 1437 // FIXME: remove this once the layout object lifecycle ASSERTS are no longer hit . | 1444 // FIXME: remove this once the layout object lifecycle ASSERTS are no longer hit . |
| 1438 class DeprecatedDisableModifyLayoutTreeStructureAsserts { | 1445 class DeprecatedDisableModifyLayoutTreeStructureAsserts { |
| 1439 WTF_MAKE_NONCOPYABLE(DeprecatedDisableModifyLayoutTreeStructureAsserts); | 1446 WTF_MAKE_NONCOPYABLE(DeprecatedDisableModifyLayoutTreeStructureAsserts); |
| 1440 public: | 1447 public: |
| 1441 DeprecatedDisableModifyLayoutTreeStructureAsserts(); | 1448 DeprecatedDisableModifyLayoutTreeStructureAsserts(); |
| 1442 | 1449 |
| 1443 static bool canModifyLayoutTreeStateInAnyState(); | 1450 static bool canModifyLayoutTreeStateInAnyState(); |
| (...skipping 213 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 1657 void showTree(const blink::LayoutObject*); | 1664 void showTree(const blink::LayoutObject*); |
| 1658 void showLineTree(const blink::LayoutObject*); | 1665 void showLineTree(const blink::LayoutObject*); |
| 1659 void showLayoutTree(const blink::LayoutObject* object1); | 1666 void showLayoutTree(const blink::LayoutObject* object1); |
| 1660 // We don't make object2 an optional parameter so that showLayoutTree | 1667 // We don't make object2 an optional parameter so that showLayoutTree |
| 1661 // can be called from gdb easily. | 1668 // can be called from gdb easily. |
| 1662 void showLayoutTree(const blink::LayoutObject* object1, const blink::LayoutObjec t* object2); | 1669 void showLayoutTree(const blink::LayoutObject* object1, const blink::LayoutObjec t* object2); |
| 1663 | 1670 |
| 1664 #endif | 1671 #endif |
| 1665 | 1672 |
| 1666 #endif // LayoutObject_h | 1673 #endif // LayoutObject_h |
| OLD | NEW |