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

Unified Diff: chrome/browser/extensions/api/automation_internal/automation_event_router.cc

Issue 2255093005: Pass accessible location change messages to the automation API. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Speculative fix to cast_shell Created 4 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/extensions/api/automation_internal/automation_event_router.cc
diff --git a/chrome/browser/extensions/api/automation_internal/automation_event_router.cc b/chrome/browser/extensions/api/automation_internal/automation_event_router.cc
index fedf90ddd914da319951afc59dacd1c31010b7a4..20619d934373e62dc15f25ff12e318944d05c238 100644
--- a/chrome/browser/extensions/api/automation_internal/automation_event_router.cc
+++ b/chrome/browser/extensions/api/automation_internal/automation_event_router.cc
@@ -88,6 +88,23 @@ void AutomationEventRouter::DispatchAccessibilityEvent(
}
}
+void AutomationEventRouter::DispatchAccessibilityLocationChange(
+ const ExtensionMsg_AccessibilityLocationChangeParams& params) {
+ for (const auto& listener : listeners_) {
+ // Skip listeners that don't want to listen to this tree.
+ if (!listener.desktop &&
+ listener.tree_ids.find(params.tree_id) == listener.tree_ids.end()) {
+ continue;
+ }
+
+ content::RenderProcessHost* rph =
+ content::RenderProcessHost::FromID(listener.process_id);
+ rph->Send(new ExtensionMsg_AccessibilityLocationChange(
+ listener.routing_id,
+ params));
+ }
+}
+
void AutomationEventRouter::DispatchTreeDestroyedEvent(
int tree_id,
content::BrowserContext* browser_context) {

Powered by Google App Engine
This is Rietveld 408576698