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

Side by Side Diff: chrome/browser/chromeos/policy/recommendation_restorer_factory.cc

Issue 16658015: Add device policies to control accessibility settings on the login screen (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fixed leaky tests. Created 7 years, 6 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
(Empty)
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #include "chrome/browser/chromeos/policy/recommendation_restorer_factory.h"
6
7 #include "chrome/browser/chromeos/policy/recommendation_restorer.h"
8 #include "chrome/browser/profiles/profile.h"
9 #include "components/browser_context_keyed_service/browser_context_dependency_ma nager.h"
10 #include "content/public/browser/browser_context.h"
11
12 namespace policy {
13
14 // static
15 RecommendationRestorerFactory* RecommendationRestorerFactory::GetInstance() {
16 return Singleton<RecommendationRestorerFactory>::get();
17 }
18
19 // static
20 RecommendationRestorer* RecommendationRestorerFactory::GetForProfile(
21 Profile* profile) {
22 return reinterpret_cast<RecommendationRestorer*>(
23 GetInstance()->GetServiceForBrowserContext(profile, false));
24 }
25
26 BrowserContextKeyedService*
27 RecommendationRestorerFactory::BuildServiceInstanceFor(
28 content::BrowserContext* context) const {
29 return new RecommendationRestorer(static_cast<Profile*>(context));
30 }
31
32 bool RecommendationRestorerFactory::ServiceIsCreatedWithBrowserContext() const {
33 return true;
34 }
35
36 RecommendationRestorerFactory::RecommendationRestorerFactory()
37 : BrowserContextKeyedServiceFactory(
38 "RecommendationRestorer",
39 BrowserContextDependencyManager::GetInstance()) {
40 }
41
42 RecommendationRestorerFactory::~RecommendationRestorerFactory() {
43 }
44
45 } // namespace policy
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698