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

Unified Diff: chrome/browser/password_manager/password_manager_internals_service_factory.cc

Issue 262583007: Password manager internals page service: introduction (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Add client registration, remove IsActive Created 6 years, 8 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/password_manager/password_manager_internals_service_factory.cc
diff --git a/chrome/browser/password_manager/password_manager_internals_service_factory.cc b/chrome/browser/password_manager/password_manager_internals_service_factory.cc
new file mode 100644
index 0000000000000000000000000000000000000000..c92850f503ddc0b0d473b783510ecabf9680e127
--- /dev/null
+++ b/chrome/browser/password_manager/password_manager_internals_service_factory.cc
@@ -0,0 +1,37 @@
+// Copyright 2014 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#include "chrome/browser/password_manager/password_manager_internals_service_factory.h"
+
+#include "chrome/browser/password_manager/password_manager_internals_service.h"
+#include "components/keyed_service/content/browser_context_dependency_manager.h"
+
+// static
+PasswordManagerInternalsService*
+PasswordManagerInternalsServiceFactory::GetForBrowserContext(
+ content::BrowserContext* context) {
+ return static_cast<PasswordManagerInternalsService*>(
+ GetInstance()->GetServiceForBrowserContext(context, /*create = */ true));
+}
+
+// static
+PasswordManagerInternalsServiceFactory*
+PasswordManagerInternalsServiceFactory::GetInstance() {
+ return Singleton<PasswordManagerInternalsServiceFactory>::get();
+}
+
+PasswordManagerInternalsServiceFactory::PasswordManagerInternalsServiceFactory()
+ : BrowserContextKeyedServiceFactory(
+ "PasswordManagerInternalsService",
+ BrowserContextDependencyManager::GetInstance()) {
+}
+
+PasswordManagerInternalsServiceFactory::
+ ~PasswordManagerInternalsServiceFactory() {
+}
+
+KeyedService* PasswordManagerInternalsServiceFactory::BuildServiceInstanceFor(
+ content::BrowserContext* /*context*/) const {
Ilya Sherman 2014/05/02 23:38:38 nit: Please leave spaces next to the asterisks, i.
vabr (Chromium) 2014/05/06 13:16:30 Done.
+ return new PasswordManagerInternalsService();
+}

Powered by Google App Engine
This is Rietveld 408576698