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

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

Issue 2849063002: Forward BrowserAccessibilityWin::get_accKeyboardShortcut to the platform node (Closed)
Patch Set: Add has check to ensure we don't override key shortcut 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 "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 542 matching lines...) Expand 10 before | Expand all | Expand 10 after
553 if (src.HasComputedStyle()) { 553 if (src.HasComputedStyle()) {
554 dst->AddStringAttribute(ui::AX_ATTR_DISPLAY, 554 dst->AddStringAttribute(ui::AX_ATTR_DISPLAY,
555 src.ComputedStyleDisplay().Utf8()); 555 src.ComputedStyleDisplay().Utf8());
556 } 556 }
557 557
558 if (src.Language().length()) { 558 if (src.Language().length()) {
559 if (parent.IsNull() || parent.Language() != src.Language()) 559 if (parent.IsNull() || parent.Language() != src.Language())
560 dst->AddStringAttribute(ui::AX_ATTR_LANGUAGE, src.Language().Utf8()); 560 dst->AddStringAttribute(ui::AX_ATTR_LANGUAGE, src.Language().Utf8());
561 } 561 }
562 562
563 if (src.KeyboardShortcut().length()) { 563 if (src.KeyboardShortcut().length() &&
564 dst->AddStringAttribute(ui::AX_ATTR_SHORTCUT, 564 !dst->HasStringAttribute(ui::AX_ATTR_KEY_SHORTCUTS)) {
565 dst->AddStringAttribute(ui::AX_ATTR_KEY_SHORTCUTS,
565 src.KeyboardShortcut().Utf8()); 566 src.KeyboardShortcut().Utf8());
566 } 567 }
567 568
568 if (!src.NextOnLine().IsDetached()) { 569 if (!src.NextOnLine().IsDetached()) {
569 dst->AddIntAttribute(ui::AX_ATTR_NEXT_ON_LINE_ID, 570 dst->AddIntAttribute(ui::AX_ATTR_NEXT_ON_LINE_ID,
570 src.NextOnLine().AxID()); 571 src.NextOnLine().AxID());
571 } 572 }
572 573
573 if (!src.PreviousOnLine().IsDetached()) { 574 if (!src.PreviousOnLine().IsDetached()) {
574 dst->AddIntAttribute(ui::AX_ATTR_PREVIOUS_ON_LINE_ID, 575 dst->AddIntAttribute(ui::AX_ATTR_PREVIOUS_ON_LINE_ID,
(...skipping 312 matching lines...) Expand 10 before | Expand all | Expand 10 after
887 return WebAXObject(); 888 return WebAXObject();
888 889
889 WebDocument document = render_frame_->GetWebFrame()->GetDocument(); 890 WebDocument document = render_frame_->GetWebFrame()->GetDocument();
890 if (!document.IsNull()) 891 if (!document.IsNull())
891 return WebAXObject::FromWebDocument(document); 892 return WebAXObject::FromWebDocument(document);
892 893
893 return WebAXObject(); 894 return WebAXObject();
894 } 895 }
895 896
896 } // namespace content 897 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/accessibility/browser_accessibility_com_win.cc ('k') | ui/accessibility/ax_enums.idl » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698