| OLD | NEW |
| 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 <set> | 7 #include <set> |
| 8 | 8 |
| 9 #include "base/strings/string_number_conversions.h" | 9 #include "base/strings/string_number_conversions.h" |
| 10 #include "base/strings/string_util.h" | 10 #include "base/strings/string_util.h" |
| (...skipping 328 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 339 if (src.actionVerb().length()) { | 339 if (src.actionVerb().length()) { |
| 340 dst->AddStringAttribute(ui::AX_ATTR_ACTION, src.actionVerb().utf8()); | 340 dst->AddStringAttribute(ui::AX_ATTR_ACTION, src.actionVerb().utf8()); |
| 341 } | 341 } |
| 342 if (src.ariaAutoComplete().length()) | 342 if (src.ariaAutoComplete().length()) |
| 343 dst->AddStringAttribute( | 343 dst->AddStringAttribute( |
| 344 ui::AX_ATTR_AUTO_COMPLETE, | 344 ui::AX_ATTR_AUTO_COMPLETE, |
| 345 src.ariaAutoComplete().utf8()); | 345 src.ariaAutoComplete().utf8()); |
| 346 if (src.isAriaReadOnly()) | 346 if (src.isAriaReadOnly()) |
| 347 dst->AddBoolAttribute(ui::AX_ATTR_ARIA_READONLY, true); | 347 dst->AddBoolAttribute(ui::AX_ATTR_ARIA_READONLY, true); |
| 348 if (src.isButtonStateMixed()) | 348 if (src.isButtonStateMixed()) |
| 349 dst->AddBoolAttribute(ui::AX_ATTR_BUTTON_MIXED, true); | 349 dst->AddBoolAttribute(ui::AX_ATTR_STATE_MIXED, true); |
| 350 if (src.canSetValueAttribute()) | 350 if (src.canSetValueAttribute()) |
| 351 dst->AddBoolAttribute(ui::AX_ATTR_CAN_SET_VALUE, true); | 351 dst->AddBoolAttribute(ui::AX_ATTR_CAN_SET_VALUE, true); |
| 352 if (src.deprecatedAccessibilityDescription().length()) { | 352 if (src.deprecatedAccessibilityDescription().length()) { |
| 353 dst->AddStringAttribute( | 353 dst->AddStringAttribute( |
| 354 ui::AX_ATTR_DESCRIPTION, | 354 ui::AX_ATTR_DESCRIPTION, |
| 355 src.deprecatedAccessibilityDescription().utf8()); | 355 src.deprecatedAccessibilityDescription().utf8()); |
| 356 } | 356 } |
| 357 if (src.hasComputedStyle()) { | 357 if (src.hasComputedStyle()) { |
| 358 dst->AddStringAttribute( | 358 dst->AddStringAttribute( |
| 359 ui::AX_ATTR_DISPLAY, | 359 ui::AX_ATTR_DISPLAY, |
| (...skipping 282 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 642 } | 642 } |
| 643 } | 643 } |
| 644 | 644 |
| 645 blink::WebDocument BlinkAXTreeSource::GetMainDocument() const { | 645 blink::WebDocument BlinkAXTreeSource::GetMainDocument() const { |
| 646 if (render_frame_ && render_frame_->GetWebFrame()) | 646 if (render_frame_ && render_frame_->GetWebFrame()) |
| 647 return render_frame_->GetWebFrame()->document(); | 647 return render_frame_->GetWebFrame()->document(); |
| 648 return WebDocument(); | 648 return WebDocument(); |
| 649 } | 649 } |
| 650 | 650 |
| 651 } // namespace content | 651 } // namespace content |
| OLD | NEW |