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

Side by Side Diff: chrome/browser/chromeos/ownership/owner_settings_service.h

Issue 270663002: Implemented profile-aware owner key loading. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fixes, rebase. Created 6 years, 7 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 2014 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 #ifndef CHROME_BROWSER_CHROMEOS_OWNERSHIP_OWNER_SETTINGS_SERVICE_H_
6 #define CHROME_BROWSER_CHROMEOS_OWNERSHIP_OWNER_SETTINGS_SERVICE_H_
7
8 #include "base/compiler_specific.h"
9 #include "base/macros.h"
10 #include "base/memory/weak_ptr.h"
11 #include "components/keyed_service/core/keyed_service.h"
12 #include "content/public/browser/notification_observer.h"
13 #include "content/public/browser/notification_registrar.h"
14
15 class Profile;
16
17 namespace chromeos {
18
19 // This class reloads owner key from profile NSS slots.
20 //
21 // TODO (ygorshenin@): move write path for device settings here
22 // (crbug.com/230018).
23 class OwnerSettingsService : public KeyedService,
24 public content::NotificationObserver {
25 public:
26 virtual ~OwnerSettingsService();
27
28 // NotificationObserver implementation:
29 virtual void Observe(int type,
30 const content::NotificationSource& source,
31 const content::NotificationDetails& details) OVERRIDE;
32
33 private:
34 friend class OwnerSettingsServiceFactory;
35
36 explicit OwnerSettingsService(Profile* profile);
37
38 void ReloadOwnerKey();
39
40 Profile* profile_;
41
42 content::NotificationRegistrar registrar_;
43
44 base::WeakPtrFactory<OwnerSettingsService> weak_factory_;
45
46 DISALLOW_COPY_AND_ASSIGN(OwnerSettingsService);
47 };
48
49 } // namespace chromeos
50
51 #endif // CHROME_BROWSER_CHROMEOS_OWNERSHIP_OWNER_SETTINGS_SERVICE_H_
OLDNEW
« no previous file with comments | « chrome/browser/chromeos/login/users/user_manager_impl.cc ('k') | chrome/browser/chromeos/ownership/owner_settings_service.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698