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

Unified Diff: Source/modules/accessibility/AXNodeObject.cpp

Issue 1012663002: Aria disabled does not apply to descendant elements (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Just some cleanup Created 5 years, 9 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/accessibility/aria-disabled-expected.txt ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/modules/accessibility/AXNodeObject.cpp
diff --git a/Source/modules/accessibility/AXNodeObject.cpp b/Source/modules/accessibility/AXNodeObject.cpp
index a1f56766d0d975ee78bac70cf5d0f66a1d0dbfa4..ef4467662a54c5653c774fd856b647175cde7b0c 100644
--- a/Source/modules/accessibility/AXNodeObject.cpp
+++ b/Source/modules/accessibility/AXNodeObject.cpp
@@ -727,8 +727,11 @@ bool AXNodeObject::isClickable() const
bool AXNodeObject::isEnabled() const
{
- if (equalIgnoringCase(getAttribute(aria_disabledAttr), "true"))
- return false;
+ for (AXObject* axObject = const_cast<AXNodeObject*>(this); axObject; axObject = axObject->parentObject()) {
dmazzoni 2015/03/16 15:45:03 I'm trying to avoid code that iterates over all an
+ const AtomicString& disabled = axObject->getAttribute(aria_disabledAttr);
+ if (equalIgnoringCase(disabled, "true"))
+ return false;
+ }
Node* node = this->node();
if (!node || !node->isElementNode())
« no previous file with comments | « LayoutTests/accessibility/aria-disabled-expected.txt ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698