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

Unified Diff: extensions/browser/mojo/keep_alive_impl.cc

Issue 671763002: Extract ProcessManager from ExtensionSystem. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebased. Created 6 years, 2 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
« no previous file with comments | « extensions/browser/mock_extension_system.cc ('k') | extensions/browser/mojo/keep_alive_impl_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: extensions/browser/mojo/keep_alive_impl.cc
diff --git a/extensions/browser/mojo/keep_alive_impl.cc b/extensions/browser/mojo/keep_alive_impl.cc
index 4073ce1ccb76a8b57f7cfe2bbe56bb2b726256b6..04e496608246e8698c0e9ccf9d0ef9ed8e3e3bd0 100644
--- a/extensions/browser/mojo/keep_alive_impl.cc
+++ b/extensions/browser/mojo/keep_alive_impl.cc
@@ -4,7 +4,6 @@
#include "extensions/browser/mojo/keep_alive_impl.h"
-#include "extensions/browser/extension_system.h"
#include "extensions/browser/process_manager.h"
namespace extensions {
@@ -19,17 +18,11 @@ void KeepAliveImpl::Create(content::BrowserContext* context,
KeepAliveImpl::KeepAliveImpl(content::BrowserContext* context,
const Extension* extension)
: context_(context), extension_(extension) {
- ExtensionSystem* system = ExtensionSystem::Get(context_);
- if (!system)
- return;
- system->process_manager()->IncrementLazyKeepaliveCount(extension_);
+ ProcessManager::Get(context_)->IncrementLazyKeepaliveCount(extension_);
}
KeepAliveImpl::~KeepAliveImpl() {
- ExtensionSystem* system = ExtensionSystem::Get(context_);
- if (!system)
- return;
- system->process_manager()->DecrementLazyKeepaliveCount(extension_);
+ ProcessManager::Get(context_)->DecrementLazyKeepaliveCount(extension_);
}
} // namespace extensions
« no previous file with comments | « extensions/browser/mock_extension_system.cc ('k') | extensions/browser/mojo/keep_alive_impl_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698