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

Unified Diff: third_party/WebKit/Source/modules/accessibility/AXObjectCacheImpl.cpp

Issue 1841333002: Various fixes for aria-activedescendant. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fixed some Blink tests. Created 4 years, 8 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 | « third_party/WebKit/Source/modules/accessibility/AXObject.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/modules/accessibility/AXObjectCacheImpl.cpp
diff --git a/third_party/WebKit/Source/modules/accessibility/AXObjectCacheImpl.cpp b/third_party/WebKit/Source/modules/accessibility/AXObjectCacheImpl.cpp
index bd3d738cb3e1b68c3df81406b9ee7e6d8685c063..eb68f4a70b4d0db4936092747f6b9430ccbd8e59 100644
--- a/third_party/WebKit/Source/modules/accessibility/AXObjectCacheImpl.cpp
+++ b/third_party/WebKit/Source/modules/accessibility/AXObjectCacheImpl.cpp
@@ -155,7 +155,7 @@ AXObject* AXObjectCacheImpl::focusedImageMapUIElement(HTMLAreaElement* areaEleme
AXObject* AXObjectCacheImpl::focusedObject()
{
if (!accessibilityEnabled())
- return 0;
+ return nullptr;
Node* focusedNode = m_document->focusedElement();
if (!focusedNode)
@@ -172,17 +172,11 @@ AXObject* AXObjectCacheImpl::focusedObject()
if (Element* focusedElementInPopup = axPopup->getDocument()->focusedElement())
focusedNode = focusedElementInPopup;
}
-
}
AXObject* obj = getOrCreate(focusedNode);
if (!obj)
- return 0;
-
- if (obj->shouldFocusActiveDescendant()) {
- if (AXObject* descendant = obj->activeDescendant())
- obj = descendant;
- }
+ return nullptr;
// the HTML element, for example, is focusable but has an AX object that is ignored
if (obj->accessibilityIsIgnored())
@@ -1140,15 +1134,6 @@ void AXObjectCacheImpl::postPlatformNotification(AXObject* obj, AXNotification n
return;
ChromeClient& client = obj->getDocument()->axObjectCacheOwner().page()->chromeClient();
-
- if (notification == AXActiveDescendantChanged
- && obj->getDocument()->focusedElement()
- && obj->getNode() == obj->getDocument()->focusedElement()) {
- // Calling handleFocusedUIElementChanged will focus the new active
- // descendant and send the AXFocusedUIElementChanged notification.
- handleFocusedUIElementChanged(0, obj->getDocument()->focusedElement());
- }
-
client.postAccessibilityNotification(obj, notification);
}
« no previous file with comments | « third_party/WebKit/Source/modules/accessibility/AXObject.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698