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

Side by Side Diff: third_party/WebKit/Source/modules/accessibility/InspectorAccessibilityAgent.cpp

Issue 2946673003: Aria-details takes an ID reference, not an ID reference list (Closed)
Patch Set: Rebase Created 3 years, 6 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 unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "modules/accessibility/InspectorAccessibilityAgent.h" 5 #include "modules/accessibility/InspectorAccessibilityAgent.h"
6 6
7 #include <memory> 7 #include <memory>
8 #include "core/HTMLNames.h" 8 #include "core/HTMLNames.h"
9 #include "core/dom/AXObjectCache.h" 9 #include "core/dom/AXObjectCache.h"
10 #include "core/dom/DOMNodeIds.h" 10 #include "core/dom/DOMNodeIds.h"
(...skipping 337 matching lines...) Expand 10 before | Expand all | Expand 10 after
348 } 348 }
349 } 349 }
350 350
351 void AddObjectAttribute(AXObjectAttribute attribute, AXObjectImpl& object) { 351 void AddObjectAttribute(AXObjectAttribute attribute, AXObjectImpl& object) {
352 switch (attribute) { 352 switch (attribute) {
353 case AXObjectAttribute::kAriaActiveDescendant: 353 case AXObjectAttribute::kAriaActiveDescendant:
354 properties_.addItem( 354 properties_.addItem(
355 CreateProperty(AXRelationshipAttributesEnum::Activedescendant, 355 CreateProperty(AXRelationshipAttributesEnum::Activedescendant,
356 CreateRelatedNodeListValue(object))); 356 CreateRelatedNodeListValue(object)));
357 break; 357 break;
358 case AXObjectAttribute::kAriaDetails:
359 properties_.addItem(
360 CreateProperty(AXRelationshipAttributesEnum::Details,
361 CreateRelatedNodeListValue(object)));
362 break;
358 case AXObjectAttribute::kAriaErrorMessage: 363 case AXObjectAttribute::kAriaErrorMessage:
359 properties_.addItem( 364 properties_.addItem(
360 CreateProperty(AXRelationshipAttributesEnum::Errormessage, 365 CreateProperty(AXRelationshipAttributesEnum::Errormessage,
361 CreateRelatedNodeListValue(object))); 366 CreateRelatedNodeListValue(object)));
362 break; 367 break;
363 } 368 }
364 } 369 }
365 370
366 void AddObjectVectorAttribute(AXObjectVectorAttribute attribute, 371 void AddObjectVectorAttribute(AXObjectVectorAttribute attribute,
367 HeapVector<Member<AXObjectImpl>>& objects) { 372 HeapVector<Member<AXObjectImpl>>& objects) {
368 switch (attribute) { 373 switch (attribute) {
369 case AXObjectVectorAttribute::kAriaControls: 374 case AXObjectVectorAttribute::kAriaControls:
370 properties_.addItem(CreateRelatedNodeListProperty( 375 properties_.addItem(CreateRelatedNodeListProperty(
371 AXRelationshipAttributesEnum::Controls, objects, aria_controlsAttr, 376 AXRelationshipAttributesEnum::Controls, objects, aria_controlsAttr,
372 *ax_object_)); 377 *ax_object_));
373 break; 378 break;
374 case AXObjectVectorAttribute::kAriaDetails:
375 properties_.addItem(CreateRelatedNodeListProperty(
376 AXRelationshipAttributesEnum::Details, objects, aria_controlsAttr,
377 *ax_object_));
378 break;
379 case AXObjectVectorAttribute::kAriaFlowTo: 379 case AXObjectVectorAttribute::kAriaFlowTo:
380 properties_.addItem(CreateRelatedNodeListProperty( 380 properties_.addItem(CreateRelatedNodeListProperty(
381 AXRelationshipAttributesEnum::Flowto, objects, aria_flowtoAttr, 381 AXRelationshipAttributesEnum::Flowto, objects, aria_flowtoAttr,
382 *ax_object_)); 382 *ax_object_));
383 break; 383 break;
384 } 384 }
385 } 385 }
386 }; 386 };
387 387
388 void FillRelationships(AXObjectImpl& ax_object, 388 void FillRelationships(AXObjectImpl& ax_object,
(...skipping 326 matching lines...) Expand 10 before | Expand all | Expand 10 after
715 } 715 }
716 } 716 }
717 717
718 DEFINE_TRACE(InspectorAccessibilityAgent) { 718 DEFINE_TRACE(InspectorAccessibilityAgent) {
719 visitor->Trace(page_); 719 visitor->Trace(page_);
720 visitor->Trace(dom_agent_); 720 visitor->Trace(dom_agent_);
721 InspectorBaseAgent::Trace(visitor); 721 InspectorBaseAgent::Trace(visitor);
722 } 722 }
723 723
724 } // namespace blink 724 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/modules/accessibility/AXObject.cpp ('k') | third_party/WebKit/public/web/WebAXEnums.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698