| Index: Source/core/page/SpatialNavigation.cpp
|
| diff --git a/Source/core/page/SpatialNavigation.cpp b/Source/core/page/SpatialNavigation.cpp
|
| index 6a8112cb6c787cc811602b52a92332af8cba13f2..c8ae77b3a70851b8f277867fa7e7b71bdfda1ad1 100644
|
| --- a/Source/core/page/SpatialNavigation.cpp
|
| +++ b/Source/core/page/SpatialNavigation.cpp
|
| @@ -496,12 +496,14 @@ bool canScrollInDirection(const LocalFrame* frame, FocusType type)
|
| static LayoutRect rectToAbsoluteCoordinates(LocalFrame* initialFrame, const LayoutRect& initialRect)
|
| {
|
| LayoutRect rect = initialRect;
|
| - for (LocalFrame* frame = initialFrame; frame; frame = frame->tree().parent()) {
|
| + for (Frame* frame = initialFrame; frame; frame = frame->tree().parent()) {
|
| + if (!frame->isLocalFrame())
|
| + continue;
|
| if (Element* element = frame->ownerElement()) {
|
| do {
|
| rect.move(element->offsetLeft(), element->offsetTop());
|
| } while ((element = element->offsetParent()));
|
| - rect.move((-frame->view()->scrollOffset()));
|
| + rect.move((-toLocalFrame(frame)->view()->scrollOffset()));
|
| }
|
| }
|
| return rect;
|
|
|