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

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

Issue 383153007: Fixes for re-enabling more MSVC level 4 warnings: Source/core/ edition (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Review comments Created 6 years, 5 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
« no previous file with comments | « Source/core/page/FrameTree.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/page/SpatialNavigation.cpp
diff --git a/Source/core/page/SpatialNavigation.cpp b/Source/core/page/SpatialNavigation.cpp
index a4915b1aabccdeb86fa6cee25ca23058149767dd..012407c22cdb4d1544c5fcb19ab4b90de7546075 100644
--- a/Source/core/page/SpatialNavigation.cpp
+++ b/Source/core/page/SpatialNavigation.cpp
@@ -500,10 +500,10 @@ static LayoutRect rectToAbsoluteCoordinates(LocalFrame* initialFrame, const Layo
if (!frame->isLocalFrame())
continue;
// FIXME: Spatial navigation is broken for OOPI.
- if (Element* element = frame->deprecatedLocalOwner()) {
- do {
+ Element* element = frame->deprecatedLocalOwner();
+ if (element) {
+ for (; element; element = element->offsetParent())
rect.move(element->offsetLeft(), element->offsetTop());
- } while ((element = element->offsetParent()));
rect.move((-toLocalFrame(frame)->view()->scrollOffset()));
}
}
« no previous file with comments | « Source/core/page/FrameTree.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698