Index: Source/core/page/FocusController.cpp |
diff --git a/Source/core/page/FocusController.cpp b/Source/core/page/FocusController.cpp |
index 4382f680fb5796be7026505d992dd3478f2ea719..6c27950d5963b2f6676b68af9606b1a64a0ada30 100644 |
--- a/Source/core/page/FocusController.cpp |
+++ b/Source/core/page/FocusController.cpp |
@@ -752,7 +752,7 @@ static void updateFocusCandidateIfNeeded(FocusType type, const FocusCandidate& c |
if (candidate.distance == maxDistance()) |
return; |
- if (candidate.isOffscreenAfterScrolling && candidate.alignment < Full) |
+ if (candidate.isOffscreenAfterScrolling) |
return; |
if (closest.isNull()) { |
@@ -777,13 +777,7 @@ static void updateFocusCandidateIfNeeded(FocusType type, const FocusCandidate& c |
return; |
} |
- if (candidate.alignment == closest.alignment) { |
- if (candidate.distance < closest.distance) |
- closest = candidate; |
- return; |
- } |
- |
- if (candidate.alignment > closest.alignment) |
+ if (candidate.distance < closest.distance) |
closest = candidate; |
} |