Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1472)

Unified Diff: Source/core/page/SpatialNavigation.cpp

Issue 336553003: Change Page::m_mainFrame to be a Frame. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Android/Mac fixes Created 6 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: Source/core/page/SpatialNavigation.cpp
diff --git a/Source/core/page/SpatialNavigation.cpp b/Source/core/page/SpatialNavigation.cpp
index 895c4561ba333c9eb9465e8d443fee99fe0fb271..2f5b4083c1d8a6a24ac05d2bab0ab127839fc097 100644
--- a/Source/core/page/SpatialNavigation.cpp
+++ b/Source/core/page/SpatialNavigation.cpp
@@ -690,7 +690,8 @@ void distanceDataForNode(FocusType type, const FocusCandidate& current, FocusCan
// Distance calculation is based on http://www.w3.org/TR/WICD/#focus-handling
candidate.distance = sqrt(euclidianDistancePow2) + navigationAxisDistance+ orthogonalAxisDistance * 2 - sqrt(overlap);
- LayoutSize viewSize = candidate.visibleNode->document().page()->mainFrame()->view()->visibleContentRect().size();
+ // FIXME: Doesn't work with OOPI.
+ LayoutSize viewSize = toLocalFrame(candidate.visibleNode->document().page()->mainFrame())->view()->visibleContentRect().size();
candidate.alignment = alignmentForRects(type, currentRect, nodeRect, viewSize);
}

Powered by Google App Engine
This is Rietveld 408576698