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

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

Issue 2826423003: Expand Chrome OS ARC support to create one tree source per package (Closed)
Patch Set: Fake out WMHelper Created 3 years, 7 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 d153c396cb3181b8faf557e1926caa257a1789cb..a55a4d97c8cb29ff8ab048e8aa5986e74e7c3ef7 100644
--- a/chrome/browser/extensions/api/automation_internal/automation_event_router.cc
+++ b/chrome/browser/extensions/api/automation_internal/automation_event_router.cc
@@ -110,6 +110,9 @@ void AutomationEventRouter::DispatchAccessibilityLocationChange(
void AutomationEventRouter::DispatchTreeDestroyedEvent(
int tree_id,
content::BrowserContext* browser_context) {
+ if (listeners_.empty())
+ return;
+
browser_context = browser_context ? browser_context : active_profile_;
std::unique_ptr<base::ListValue> args(
api::automation_internal::OnAccessibilityTreeDestroyed::Create(tree_id));

Powered by Google App Engine
This is Rietveld 408576698