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

Unified Diff: ui/accessibility/platform/ax_platform_node_auralinux.cc

Issue 1589623002: Keep track of accessibility focus across windows. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Final suggestions Created 4 years, 10 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ui/accessibility/ax_tree_unittest.cc ('k') | ui/accessibility/platform/ax_platform_node_win.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/accessibility/platform/ax_platform_node_auralinux.cc
diff --git a/ui/accessibility/platform/ax_platform_node_auralinux.cc b/ui/accessibility/platform/ax_platform_node_auralinux.cc
index 801c3473e6686e12c667165fb1cf23576331a53e..04e96c02ba5c4a3771e6713e3a42d5869b628528 100644
--- a/ui/accessibility/platform/ax_platform_node_auralinux.cc
+++ b/ui/accessibility/platform/ax_platform_node_auralinux.cc
@@ -448,14 +448,15 @@ void AXPlatformNodeAuraLinux::GetAtkState(AtkStateSet* atk_state_set) {
atk_state_set_add_state(atk_state_set, ATK_STATE_EXPANDED);
if (state & (1 << ui::AX_STATE_FOCUSABLE))
atk_state_set_add_state(atk_state_set, ATK_STATE_FOCUSABLE);
- if (state & (1 << ui::AX_STATE_FOCUSED))
- atk_state_set_add_state(atk_state_set, ATK_STATE_FOCUSED);
if (state & (1 << ui::AX_STATE_PRESSED))
atk_state_set_add_state(atk_state_set, ATK_STATE_PRESSED);
if (state & (1 << ui::AX_STATE_SELECTABLE))
atk_state_set_add_state(atk_state_set, ATK_STATE_SELECTABLE);
if (state & (1 << ui::AX_STATE_SELECTED))
atk_state_set_add_state(atk_state_set, ATK_STATE_SELECTED);
+
+ if (delegate_->GetFocus() == GetNativeViewAccessible())
+ atk_state_set_add_state(atk_state_set, ATK_STATE_FOCUSED);
}
void AXPlatformNodeAuraLinux::GetAtkRelations(AtkRelationSet* atk_relation_set)
« no previous file with comments | « ui/accessibility/ax_tree_unittest.cc ('k') | ui/accessibility/platform/ax_platform_node_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698