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

Unified Diff: Source/core/html/HTMLAnchorElement.cpp

Issue 15238002: Disallow tabsToLinks setting to prevent tabbing to anchor with tabIndex. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: And update expected result after removing accidentally added line Created 7 years, 3 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 | « LayoutTests/fast/events/tab-focus-anchor-tab-to-links-expected.txt ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/html/HTMLAnchorElement.cpp
diff --git a/Source/core/html/HTMLAnchorElement.cpp b/Source/core/html/HTMLAnchorElement.cpp
index 5fa5a2b23b2b4897a611a042d475cf9f94e4c652..43ee0a17952067dda10ab4ada869d4649d81f2a6 100644
--- a/Source/core/html/HTMLAnchorElement.cpp
+++ b/Source/core/html/HTMLAnchorElement.cpp
@@ -163,6 +163,9 @@ bool HTMLAnchorElement::isMouseFocusable() const
bool HTMLAnchorElement::isKeyboardFocusable() const
{
+ if (isFocusable() && Element::supportsFocus())
+ return HTMLElement::isKeyboardFocusable();
+
if (isLink()) {
Page* page = document().page();
if (!page)
« no previous file with comments | « LayoutTests/fast/events/tab-focus-anchor-tab-to-links-expected.txt ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698