 Chromium Code Reviews
 Chromium Code Reviews Issue 18601002:
  Add infrastructure for partial layouts  (Closed) 
  Base URL: svn://svn.chromium.org/blink/trunk
    
  
    Issue 18601002:
  Add infrastructure for partial layouts  (Closed) 
  Base URL: svn://svn.chromium.org/blink/trunk| Index: Source/core/rendering/RenderObject.h | 
| diff --git a/Source/core/rendering/RenderObject.h b/Source/core/rendering/RenderObject.h | 
| index 6dff5539192471bd58e8839a42408a7f6c1f9afa..0ccba183242a10888f3c6356aa39a584d8a0674d 100644 | 
| --- a/Source/core/rendering/RenderObject.h | 
| +++ b/Source/core/rendering/RenderObject.h | 
| @@ -67,6 +67,7 @@ class RenderNamedFlowThread; | 
| class RenderSVGResourceContainer; | 
| class RenderTable; | 
| class RenderTheme; | 
| +class RenderView; | 
| class TransformState; | 
| struct PaintInfo; | 
| @@ -589,6 +590,7 @@ public: | 
| virtual void updateDragState(bool dragOn); | 
| RenderView* view() const { return document()->renderView(); }; | 
| + virtual FrameView* frameView() const; | 
| 
esprehn
2013/08/23 20:47:27
frameView() should not be virtual
 
pdr.
2013/08/26 05:50:40
Done.
 | 
| // Returns true if this renderer is rooted, and optionally returns the hosting view (the root of the hierarchy). | 
| bool isRooted(RenderView** = 0) const; | 
| @@ -674,6 +676,9 @@ public: | 
| void forceLayout(); | 
| void forceChildLayout(); | 
| + // True if we can abort layout, leaving a partially laid out tree. | 
| + virtual bool supportsPartialLayout() const { return false; } | 
| + | 
| // used for element state updates that cannot be fixed with a | 
| // repaint and do not need a relayout | 
| virtual void updateFromElement() { } | 
| @@ -1073,6 +1078,7 @@ private: | 
| #ifndef NDEBUG | 
| void checkBlockPositionedObjectsNeedLayout(); | 
| + void checkNotInPartialLayout(); | 
| #endif | 
| RefPtr<RenderStyle> m_style; | 
| @@ -1243,6 +1249,9 @@ inline bool RenderObject::isBeforeOrAfterContent() const | 
| inline void RenderObject::setNeedsLayout(MarkingBehavior markParents, SubtreeLayoutScope* layouter) | 
| { | 
| +#ifndef NDEBUG | 
| + checkNotInPartialLayout(); | 
| +#endif | 
| ASSERT(!isSetNeedsLayoutForbidden()); | 
| bool alreadyNeededLayout = m_bitfields.selfNeedsLayout(); | 
| setSelfNeedsLayout(true); | 
| @@ -1256,6 +1265,9 @@ inline void RenderObject::setNeedsLayout(MarkingBehavior markParents, SubtreeLay | 
| inline void RenderObject::clearNeedsLayout() | 
| { | 
| +#ifndef NDEBUG | 
| + checkNotInPartialLayout(); | 
| +#endif | 
| setSelfNeedsLayout(false); | 
| setEverHadLayout(true); | 
| setPosChildNeedsLayout(false); |