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

Unified Diff: chrome/browser/extensions/api/downloads/downloads_api.cc

Issue 11440004: Remove deprecated extension EventRouter APIs. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 8 years 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/downloads/downloads_api.cc
diff --git a/chrome/browser/extensions/api/downloads/downloads_api.cc b/chrome/browser/extensions/api/downloads/downloads_api.cc
index 9ee1954712d33bd84591c6b7b6eedbf8b7b80e12..f32af4833d1cfccbc459c00ca8369755bf94cc96 100644
--- a/chrome/browser/extensions/api/downloads/downloads_api.cc
+++ b/chrome/browser/extensions/api/downloads/downloads_api.cc
@@ -486,9 +486,11 @@ void DispatchEventInternal(
scoped_ptr<base::ListValue> event_args) {
if (!extensions::ExtensionSystem::Get(target_profile)->event_router())
return;
+ scoped_ptr<extensions::Event> event(new extensions::Event(
+ event_name, event_args.Pass()));
+ event->restrict_to_profile = target_profile;
extensions::ExtensionSystem::Get(target_profile)->event_router()->
- DispatchEventToRenderers(event_name, event_args.Pass(), target_profile,
- GURL(), extensions::EventFilteringInfo());
+ BroadcastEvent(event.Pass());
ExtensionDownloadsEventRouter::DownloadsNotificationSource
notification_source;
notification_source.event_name = event_name;

Powered by Google App Engine
This is Rietveld 408576698