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

Unified Diff: chrome/browser/extensions/api/processes/processes_api.h

Issue 166053003: Move ProfileKeyedAPI implementations to take BrowserContext in the constructor (part 2). (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: | Created 6 years, 10 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/processes/processes_api.h
diff --git a/chrome/browser/extensions/api/processes/processes_api.h b/chrome/browser/extensions/api/processes/processes_api.h
index 84688838b05b6a9923387e5b0e7eb008e34c269d..0bc67b4128246d6fd252a04081b290e738e501c3 100644
--- a/chrome/browser/extensions/api/processes/processes_api.h
+++ b/chrome/browser/extensions/api/processes/processes_api.h
@@ -18,12 +18,14 @@
#include "content/public/browser/render_widget_host.h"
#include "extensions/browser/event_router.h"
-class Profile;
-
namespace base {
class ListValue;
}
+namespace content {
+class BrowserContext;
+}
+
namespace extensions {
// Observes the Task Manager and routes the notifications as events to the
@@ -31,7 +33,7 @@ namespace extensions {
class ProcessesEventRouter : public TaskManagerModelObserver,
public content::NotificationObserver {
public:
- explicit ProcessesEventRouter(Profile* profile);
+ explicit ProcessesEventRouter(content::BrowserContext* context);
virtual ~ProcessesEventRouter();
// Called when an extension process wants to listen to process events.
@@ -76,7 +78,7 @@ class ProcessesEventRouter : public TaskManagerModelObserver,
// Used for tracking registrations to process related notifications.
content::NotificationRegistrar registrar_;
- Profile* profile_;
+ content::BrowserContext* browser_context_;
// TaskManager to observe for updates.
TaskManagerModel* model_;
@@ -95,7 +97,7 @@ class ProcessesEventRouter : public TaskManagerModelObserver,
class ProcessesAPI : public ProfileKeyedAPI,
public EventRouter::Observer {
public:
- explicit ProcessesAPI(Profile* profile);
+ explicit ProcessesAPI(content::BrowserContext* context);
virtual ~ProcessesAPI();
// BrowserContextKeyedService implementation.
@@ -105,7 +107,7 @@ class ProcessesAPI : public ProfileKeyedAPI,
static ProfileKeyedAPIFactory<ProcessesAPI>* GetFactoryInstance();
// Convenience method to get the ProcessesAPI for a profile.
- static ProcessesAPI* Get(Profile* profile);
+ static ProcessesAPI* Get(content::BrowserContext* context);
ProcessesEventRouter* processes_event_router();
@@ -116,7 +118,7 @@ class ProcessesAPI : public ProfileKeyedAPI,
private:
friend class ProfileKeyedAPIFactory<ProcessesAPI>;
- Profile* profile_;
+ content::BrowserContext* browser_context_;
// ProfileKeyedAPI implementation.
static const char* service_name() {
« no previous file with comments | « chrome/browser/extensions/api/preference/preference_api.cc ('k') | chrome/browser/extensions/api/processes/processes_api.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698