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

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

Issue 1014573010: Get rid of postToElement argument for accessibility notifications. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@postnotification_1
Patch Set: Rebaseline test 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 | « Source/modules/accessibility/AXLayoutObject.h ('k') | Source/modules/accessibility/AXMenuList.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/modules/accessibility/AXLayoutObject.cpp
diff --git a/Source/modules/accessibility/AXLayoutObject.cpp b/Source/modules/accessibility/AXLayoutObject.cpp
index 00fbc55a8f56c92da69213ea30b83fb9ac3ea645..a473c6a220e76073ed1a711d4a794f122cb8ba10 100644
--- a/Source/modules/accessibility/AXLayoutObject.cpp
+++ b/Source/modules/accessibility/AXLayoutObject.cpp
@@ -1560,17 +1560,6 @@ void AXLayoutObject::clearChildren()
m_childrenDirty = false;
}
-AXObject* AXLayoutObject::observableObject() const
-{
- // Find the object going up the parent chain that is used in accessibility to monitor certain notifications.
- for (LayoutObject* layoutObject = m_layoutObject; layoutObject && layoutObject->node(); layoutObject = layoutObject->parent()) {
- if (layoutObjectIsObservable(layoutObject))
- return axObjectCache()->getOrCreate(layoutObject);
- }
-
- return 0;
-}
-
//
// Properties of the object's owning document or page.
//
@@ -1741,7 +1730,7 @@ void AXLayoutObject::handleActiveDescendantChanged()
AXLayoutObject* activedescendant = toAXLayoutObject(activeDescendant());
if (activedescendant && shouldNotifyActiveDescendant())
- toAXObjectCacheImpl(doc.axObjectCache())->postNotification(m_layoutObject, AXObjectCacheImpl::AXActiveDescendantChanged, true);
+ toAXObjectCacheImpl(doc.axObjectCache())->postNotification(m_layoutObject, AXObjectCacheImpl::AXActiveDescendantChanged);
}
void AXLayoutObject::handleAriaExpandedChanged()
@@ -1770,7 +1759,7 @@ void AXLayoutObject::handleAriaExpandedChanged()
// Post that the row count changed.
if (containerParent)
- axObjectCache()->postNotification(containerParent, AXObjectCacheImpl::AXRowCountChanged, true);
+ axObjectCache()->postNotification(containerParent, AXObjectCacheImpl::AXRowCountChanged);
// Post that the specific row either collapsed or expanded.
AccessibilityExpanded expanded = isExpanded();
@@ -1782,7 +1771,7 @@ void AXLayoutObject::handleAriaExpandedChanged()
if (expanded == ExpandedCollapsed)
notification = AXObjectCacheImpl::AXRowCollapsed;
- axObjectCache()->postNotification(this, notification, true);
+ axObjectCache()->postNotification(this, notification);
}
}
@@ -2032,24 +2021,6 @@ AXObject* AXLayoutObject::accessibilityImageMapHitTest(HTMLAreaElement* area, co
return 0;
}
-bool AXLayoutObject::layoutObjectIsObservable(LayoutObject* layoutObject) const
-{
- // AX clients will listen for AXValueChange on a text control.
- if (layoutObject->isTextControl())
- return true;
-
- // AX clients will listen for AXSelectedChildrenChanged on listboxes.
- Node* node = layoutObject->node();
- if (nodeHasRole(node, "listbox") || (layoutObject->isBoxModelObject() && toLayoutBoxModelObject(layoutObject)->isListBox()))
- return true;
-
- // Textboxes should send out notifications.
- if (nodeHasRole(node, "textbox"))
- return true;
-
- return false;
-}
-
LayoutObject* AXLayoutObject::layoutParentObject() const
{
if (!m_layoutObject)
« no previous file with comments | « Source/modules/accessibility/AXLayoutObject.h ('k') | Source/modules/accessibility/AXMenuList.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698