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

Unified Diff: chrome/browser/extensions/event_router.h

Issue 69883007: Extract chrome.runtime API code from extensions::EventRouter (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix chromeos Created 7 years, 1 month 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/event_router.h
diff --git a/chrome/browser/extensions/event_router.h b/chrome/browser/extensions/event_router.h
index 7e027a05240cc8d2b624f6f7c8c513783efe9597..371c0210d3bd7b67189420f94b1d34445759f8a6 100644
--- a/chrome/browser/extensions/event_router.h
+++ b/chrome/browser/extensions/event_router.h
@@ -24,7 +24,6 @@
class GURL;
class PrefService;
-class Profile;
namespace content {
class BrowserContext;
@@ -68,7 +67,7 @@ class EventRouter : public content::NotificationObserver,
// Sends an event via ipc_sender to the given extension. Can be called on any
// thread.
static void DispatchEvent(IPC::Sender* ipc_sender,
- void* profile_id,
+ void* browser_context_id,
const std::string& extension_id,
const std::string& event_name,
scoped_ptr<base::ListValue> event_args,
@@ -174,7 +173,7 @@ class EventRouter : public content::NotificationObserver,
// Records an event notification in the extension activity log. Can be
// called from any thread.
- static void LogExtensionEventMessage(void* profile_id,
+ static void LogExtensionEventMessage(void* browser_context_id,
const std::string& extension_id,
const std::string& event_name,
scoped_ptr<base::ListValue> event_args);
@@ -182,7 +181,7 @@ class EventRouter : public content::NotificationObserver,
// TODO(gdk): Document this.
static void DispatchExtensionMessage(
IPC::Sender* ipc_sender,
- void* profile_id,
+ void* browser_context_id,
const std::string& extension_id,
const std::string& event_name,
base::ListValue* event_args,
@@ -257,7 +256,7 @@ class EventRouter : public content::NotificationObserver,
// static
static void IncrementInFlightEventsOnUI(
- void* profile_id,
+ void* browser_context_id,
const std::string& extension_id);
void DispatchPendingEvent(const linked_ptr<Event>& event,
@@ -269,7 +268,8 @@ class EventRouter : public content::NotificationObserver,
content::BrowserContext* browser_context_;
- // The ExtensionPrefs associated with |profile_|. May be NULL in tests.
+ // The ExtensionPrefs associated with |browser_context_|. May be NULL in
+ // tests.
ExtensionPrefs* extension_prefs_;
content::NotificationRegistrar registrar_;
@@ -279,11 +279,6 @@ class EventRouter : public content::NotificationObserver,
typedef base::hash_map<std::string, Observer*> ObserverMap;
ObserverMap observers_;
- // True if we should dispatch the chrome.runtime.onInstalled event with
- // reason "chrome_update" upon loading each extension.
- // TODO(jamescook): Move this to RuntimeEventRouter.
- bool dispatch_chrome_updated_event_;
-
DISALLOW_COPY_AND_ASSIGN(EventRouter);
};
« no previous file with comments | « chrome/browser/extensions/chrome_extensions_browser_client.cc ('k') | chrome/browser/extensions/event_router.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698