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

Side by Side Diff: chrome/browser/supervised_user/supervised_user_service_factory.h

Issue 2776493005: Convert SupervisedUserResourceThrottle to a NavigationThrottle. (Closed)
Patch Set: Fix Android Created 3 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 unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CHROME_BROWSER_SUPERVISED_USER_SUPERVISED_USER_SERVICE_FACTORY_H_ 5 #ifndef CHROME_BROWSER_SUPERVISED_USER_SUPERVISED_USER_SERVICE_FACTORY_H_
6 #define CHROME_BROWSER_SUPERVISED_USER_SUPERVISED_USER_SERVICE_FACTORY_H_ 6 #define CHROME_BROWSER_SUPERVISED_USER_SUPERVISED_USER_SERVICE_FACTORY_H_
7 7
8 #include "base/memory/singleton.h" 8 #include "base/memory/singleton.h"
9 #include "chrome/browser/supervised_user/supervised_users.h" 9 #include "chrome/browser/supervised_user/supervised_users.h"
10 #include "components/keyed_service/content/browser_context_keyed_service_factory .h" 10 #include "components/keyed_service/content/browser_context_keyed_service_factory .h"
11 11
12 namespace content {
13 class BrowserContext;
14 }
15
12 class Profile; 16 class Profile;
13 class SupervisedUserService; 17 class SupervisedUserService;
14 18
15 class SupervisedUserServiceFactory : public BrowserContextKeyedServiceFactory { 19 class SupervisedUserServiceFactory : public BrowserContextKeyedServiceFactory {
16 public: 20 public:
17 static SupervisedUserService* GetForProfile(Profile* profile); 21 static SupervisedUserService* GetForProfile(
22 content::BrowserContext* browser_context);
Marc Treib 2017/03/28 10:22:58 Is this change actually required? If so, the metho
mmenke 2017/03/28 17:55:05 It's not really needed, I just was horrified by:
18 23
19 static SupervisedUserServiceFactory* GetInstance(); 24 static SupervisedUserServiceFactory* GetInstance();
20 25
21 // Used to create instances for testing. 26 // Used to create instances for testing.
22 static KeyedService* BuildInstanceFor(Profile* profile); 27 static KeyedService* BuildInstanceFor(Profile* profile);
23 28
24 private: 29 private:
25 friend struct base::DefaultSingletonTraits<SupervisedUserServiceFactory>; 30 friend struct base::DefaultSingletonTraits<SupervisedUserServiceFactory>;
26 31
27 SupervisedUserServiceFactory(); 32 SupervisedUserServiceFactory();
28 ~SupervisedUserServiceFactory() override; 33 ~SupervisedUserServiceFactory() override;
29 34
30 // BrowserContextKeyedServiceFactory: 35 // BrowserContextKeyedServiceFactory:
31 content::BrowserContext* GetBrowserContextToUse( 36 content::BrowserContext* GetBrowserContextToUse(
32 content::BrowserContext* context) const override; 37 content::BrowserContext* context) const override;
33 KeyedService* BuildServiceInstanceFor( 38 KeyedService* BuildServiceInstanceFor(
34 content::BrowserContext* profile) const override; 39 content::BrowserContext* profile) const override;
35 }; 40 };
36 41
37 #endif // CHROME_BROWSER_SUPERVISED_USER_SUPERVISED_USER_SERVICE_FACTORY_H_ 42 #endif // CHROME_BROWSER_SUPERVISED_USER_SUPERVISED_USER_SERVICE_FACTORY_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698