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

Side by Side Diff: content/renderer/accessibility/blink_ax_tree_source.cc

Issue 2957973003: Automatically fire AX events on Win based on tree changes (Closed)
Patch Set: Audit all events, manually test with JAWS and NVDA Created 3 years, 4 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 "content/renderer/accessibility/blink_ax_tree_source.h" 5 #include "content/renderer/accessibility/blink_ax_tree_source.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 8
9 #include <set> 9 #include <set>
10 10
(...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after
94 break; 94 break;
95 default: 95 default:
96 NOTREACHED(); 96 NOTREACHED();
97 } 97 }
98 } 98 }
99 99
100 void AddObjectAttribute(WebAXObjectAttribute attribute, 100 void AddObjectAttribute(WebAXObjectAttribute attribute,
101 const WebAXObject& value) override { 101 const WebAXObject& value) override {
102 switch (attribute) { 102 switch (attribute) {
103 case WebAXObjectAttribute::kAriaActiveDescendant: 103 case WebAXObjectAttribute::kAriaActiveDescendant:
104 dst_->AddIntAttribute(ui::AX_ATTR_ACTIVEDESCENDANT_ID, value.AxID()); 104 // TODO(dmazzoni): WebAXObject::ActiveDescendant currently returns
105 // more information than the sparse interface does.
105 break; 106 break;
106 case WebAXObjectAttribute::kAriaDetails: 107 case WebAXObjectAttribute::kAriaDetails:
107 dst_->AddIntAttribute(ui::AX_ATTR_DETAILS_ID, value.AxID()); 108 dst_->AddIntAttribute(ui::AX_ATTR_DETAILS_ID, value.AxID());
108 break; 109 break;
109 case WebAXObjectAttribute::kAriaErrorMessage: 110 case WebAXObjectAttribute::kAriaErrorMessage:
110 dst_->AddIntAttribute(ui::AX_ATTR_ERRORMESSAGE_ID, value.AxID()); 111 dst_->AddIntAttribute(ui::AX_ATTR_ERRORMESSAGE_ID, value.AxID());
111 break; 112 break;
112 default: 113 default:
113 NOTREACHED(); 114 NOTREACHED();
114 } 115 }
(...skipping 783 matching lines...) Expand 10 before | Expand all | Expand 10 after
898 return WebAXObject(); 899 return WebAXObject();
899 900
900 WebDocument document = render_frame_->GetWebFrame()->GetDocument(); 901 WebDocument document = render_frame_->GetWebFrame()->GetDocument();
901 if (!document.IsNull()) 902 if (!document.IsNull())
902 return WebAXObject::FromWebDocument(document); 903 return WebAXObject::FromWebDocument(document);
903 904
904 return WebAXObject(); 905 return WebAXObject();
905 } 906 }
906 907
907 } // namespace content 908 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698