| Index: third_party/WebKit/Source/modules/accessibility/InspectorAccessibilityAgent.cpp
|
| diff --git a/third_party/WebKit/Source/modules/accessibility/InspectorAccessibilityAgent.cpp b/third_party/WebKit/Source/modules/accessibility/InspectorAccessibilityAgent.cpp
|
| index a3c0f837ae6b3a2d4a3e82454de75b6ee740cf4b..e9487a3ca677c164c5bb523e8fa9f14cc9565e9a 100644
|
| --- a/third_party/WebKit/Source/modules/accessibility/InspectorAccessibilityAgent.cpp
|
| +++ b/third_party/WebKit/Source/modules/accessibility/InspectorAccessibilityAgent.cpp
|
| @@ -156,6 +156,10 @@ bool roleAllowsSelected(AccessibilityRole role) {
|
| role == RowHeaderRole || role == TreeItemRole;
|
| }
|
|
|
| +bool roleAllowsModal(AccessibilityRole role) {
|
| + return role == DialogRole || role == AlertDialogRole;
|
| +}
|
| +
|
| void fillWidgetProperties(AXObject& axObject,
|
| protocol::Array<AXProperty>& properties) {
|
| AccessibilityRole role = axObject.roleValue();
|
| @@ -344,7 +348,10 @@ class SparseAttributeAXPropertyAdapter
|
| void addBoolAttribute(AXBoolAttribute attribute, bool value) {
|
| switch (attribute) {
|
| case AXBoolAttribute::AriaModal:
|
| - // TODO
|
| + if (roleAllowsModal(m_axObject->roleValue())) {
|
| + m_properties.addItem(createProperty(AXWidgetStatesEnum::Modal,
|
| + createBooleanValue(value)));
|
| + }
|
| break;
|
| }
|
| }
|
| @@ -352,10 +359,12 @@ class SparseAttributeAXPropertyAdapter
|
| void addStringAttribute(AXStringAttribute attribute, const String& value) {
|
| switch (attribute) {
|
| case AXStringAttribute::AriaKeyShortcuts:
|
| - // TODO
|
| + m_properties.addItem(createProperty(
|
| + AXWidgetAttributesEnum::Keyshortcuts, createValue(value)));
|
| break;
|
| case AXStringAttribute::AriaRoleDescription:
|
| - // TODO
|
| + m_properties.addItem(createProperty(
|
| + AXWidgetAttributesEnum::Roledescription, createValue(value)));
|
| break;
|
| }
|
| }
|
| @@ -368,7 +377,9 @@ class SparseAttributeAXPropertyAdapter
|
| createRelatedNodeListValue(*object)));
|
| break;
|
| case AXObjectAttribute::AriaErrorMessage:
|
| - // TODO
|
| + m_properties.addItem(
|
| + createProperty(AXRelationshipAttributesEnum::Errormessage,
|
| + createRelatedNodeListValue(*object)));
|
| break;
|
| }
|
| }
|
| @@ -382,7 +393,9 @@ class SparseAttributeAXPropertyAdapter
|
| *m_axObject));
|
| break;
|
| case AXObjectVectorAttribute::AriaDetails:
|
| - // TODO
|
| + m_properties.addItem(createRelatedNodeListProperty(
|
| + AXRelationshipAttributesEnum::Details, objects, aria_controlsAttr,
|
| + *m_axObject));
|
| break;
|
| case AXObjectVectorAttribute::AriaFlowTo:
|
| m_properties.addItem(createRelatedNodeListProperty(
|
|
|