summaryrefslogtreecommitdiffstats
path: root/Source/WebCore/page/SpatialNavigation.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'Source/WebCore/page/SpatialNavigation.cpp')
-rw-r--r--Source/WebCore/page/SpatialNavigation.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/Source/WebCore/page/SpatialNavigation.cpp b/Source/WebCore/page/SpatialNavigation.cpp
index 15d3639..26b24aa 100644
--- a/Source/WebCore/page/SpatialNavigation.cpp
+++ b/Source/WebCore/page/SpatialNavigation.cpp
@@ -300,6 +300,8 @@ bool hasOffscreenRect(Node* node, FocusDirection direction)
if (!frameView)
return true;
+ ASSERT(!frameView->needsLayout());
+
IntRect containerViewportRect = frameView->visibleContentRect();
// We want to select a node if it is currently off screen, but will be
// exposed after we scroll. Adjust the viewport to post-scrolling position.
@@ -517,7 +519,7 @@ static IntRect rectToAbsoluteCoordinates(Frame* initialFrame, const IntRect& ini
IntRect nodeRectInAbsoluteCoordinates(Node* node, bool ignoreBorder)
{
- ASSERT(node && node->renderer());
+ ASSERT(node && node->renderer() && !node->document()->view()->needsLayout());
if (node->isDocumentNode())
return frameRectInAbsoluteCoordinates(static_cast<Document*>(node)->frame());