Index: Source/core/page/FrameView.h |
diff --git a/Source/core/page/FrameView.h b/Source/core/page/FrameView.h |
index 3e77cc62cb3586a92fcc12725744734b5cdf70fe..6f88d5ab7f696444e4badac638db7bbc86026e80 100644 |
--- a/Source/core/page/FrameView.h |
+++ b/Source/core/page/FrameView.h |
@@ -335,6 +335,11 @@ public: |
// DEPRECATED: Use viewportConstrainedVisibleContentRect() instead. |
IntSize scrollOffsetForFixedPosition() const; |
+ bool shouldStopPartialLayout() const { return m_shouldStopPartialLayout; } |
+ bool checkPartialLayoutComplete(RenderObject*); |
+ void setStopLayoutAtRenderer(RenderObject* renderer) { m_stopLayoutAtRenderer = renderer; } |
+ void resetPartialLayoutState() { m_stopLayoutAtRenderer = 0; m_shouldStopPartialLayout = false; } |
+ |
protected: |
virtual bool scrollContentsFastPath(const IntSize& scrollDelta, const IntRect& rectToScroll, const IntRect& clipRect); |
virtual void scrollContentsSlowPath(const IntRect& updateRect); |
@@ -420,6 +425,10 @@ private: |
virtual AXObjectCache* axObjectCache() const; |
void removeFromAXObjectCache(); |
+#ifndef NDEBUG |
+ void checkPartialLayoutAllowed(); |
+#endif |
+ |
static double s_currentFrameTimeStamp; // used for detecting decoded resource thrash in the cache |
static bool s_inPaintContents; |
@@ -528,8 +537,26 @@ private: |
bool m_hasSoftwareFilters; |
float m_visibleContentScaleFactor; |
+ |
+ bool m_shouldStopPartialLayout; |
+ RenderObject* m_stopLayoutAtRenderer; |
}; |
+inline bool FrameView::checkPartialLayoutComplete(RenderObject* renderer) |
+{ |
+ if (m_shouldStopPartialLayout) |
+ return true; |
+ |
+ if (renderer == m_stopLayoutAtRenderer) { |
+#ifndef NDEBUG |
+ checkPartialLayoutAllowed(); |
+#endif |
+ m_shouldStopPartialLayout = true; |
eseidel
2013/08/20 21:00:39
I think when you do this, you should also clear m_
pdr.
2013/08/26 05:50:40
Done.
|
+ return true; |
+ } |
+ return false; |
+} |
+ |
inline void FrameView::incrementVisuallyNonEmptyCharacterCount(unsigned count) |
{ |
if (m_isVisuallyNonEmpty) |