Index: Source/core/html/HTMLAnchorElement.cpp |
diff --git a/Source/core/html/HTMLAnchorElement.cpp b/Source/core/html/HTMLAnchorElement.cpp |
index 6e688ce98c887adc5fcced2ccfed385ffbc58a0f..200abfe38f5f357c8797b014c1058256a813d7f5 100644 |
--- a/Source/core/html/HTMLAnchorElement.cpp |
+++ b/Source/core/html/HTMLAnchorElement.cpp |
@@ -163,12 +163,14 @@ bool HTMLAnchorElement::isMouseFocusable() const |
bool HTMLAnchorElement::isKeyboardFocusable() const |
{ |
- if (!isLink()) |
- return HTMLElement::isKeyboardFocusable(); |
- |
if (!isFocusable()) |
return false; |
+ // If the tab index is set explicitly, ignore the tabsToLinks |
+ // setting and empty bounding box check. |
+ if (Element::supportsFocus()) |
+ return HTMLElement::isKeyboardFocusable(); |
+ |
Page* page = document().page(); |
if (!page) |
return false; |