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

Unified Diff: chrome/browser/ui/aura/accessibility/automation_manager_aura.cc

Issue 2795843002: Move implementation of accessibility actions to views::View (Closed)
Patch Set: Fix win compile Created 3 years, 9 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
Index: chrome/browser/ui/aura/accessibility/automation_manager_aura.cc
diff --git a/chrome/browser/ui/aura/accessibility/automation_manager_aura.cc b/chrome/browser/ui/aura/accessibility/automation_manager_aura.cc
index ad9122d0f8c7d6b6fe76dc0c83db5212087809a7..462a087b66268f1f3da7eb392122f69c8f60ca99 100644
--- a/chrome/browser/ui/aura/accessibility/automation_manager_aura.cc
+++ b/chrome/browser/ui/aura/accessibility/automation_manager_aura.cc
@@ -85,55 +85,7 @@ void AutomationManagerAura::PerformAction(
const ui::AXActionData& data) {
CHECK(enabled_);
- if (current_tree_->HandleAccessibleAction(data)) {
- // This accessible action is handled by custom action implemented by the
- // target view.
- return;
- }
-
- switch (data.action) {
- case ui::AX_ACTION_DO_DEFAULT:
- current_tree_->DoDefault(data.target_node_id);
- break;
- case ui::AX_ACTION_FOCUS:
- current_tree_->Focus(data.target_node_id);
- break;
- case ui::AX_ACTION_SCROLL_TO_MAKE_VISIBLE:
- current_tree_->MakeVisible(data.target_node_id);
- break;
- case ui::AX_ACTION_SET_SELECTION:
- if (data.anchor_node_id != data.focus_node_id) {
- NOTREACHED();
- return;
- }
- current_tree_->SetSelection(
- data.anchor_node_id, data.anchor_offset, data.focus_offset);
- break;
- case ui::AX_ACTION_SHOW_CONTEXT_MENU:
- current_tree_->ShowContextMenu(data.target_node_id);
- break;
- case ui::AX_ACTION_SET_ACCESSIBILITY_FOCUS:
- // Sent by ChromeVox but doesn't need to be handled by aura.
- break;
- case ui::AX_ACTION_SET_SEQUENTIAL_FOCUS_NAVIGATION_STARTING_POINT:
- // Sent by ChromeVox but doesn't need to be handled by aura.
- break;
- case ui::AX_ACTION_BLUR:
- case ui::AX_ACTION_DECREMENT:
- case ui::AX_ACTION_GET_IMAGE_DATA:
- case ui::AX_ACTION_HIT_TEST:
- case ui::AX_ACTION_INCREMENT:
- case ui::AX_ACTION_REPLACE_SELECTED_TEXT:
- case ui::AX_ACTION_SCROLL_TO_POINT:
- case ui::AX_ACTION_SET_SCROLL_OFFSET:
- case ui::AX_ACTION_SET_VALUE:
- // Not implemented yet.
- NOTREACHED();
- break;
- case ui::AX_ACTION_NONE:
- NOTREACHED();
- break;
- }
+ current_tree_->HandleAccessibleAction(data);
}
void AutomationManagerAura::OnChildWindowRemoved(

Powered by Google App Engine
This is Rietveld 408576698