OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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_PASSWORD_MANAGER_PASSWORD_STORE_X_H_ | 5 #ifndef CHROME_BROWSER_PASSWORD_MANAGER_PASSWORD_STORE_X_H_ |
6 #define CHROME_BROWSER_PASSWORD_MANAGER_PASSWORD_STORE_X_H_ | 6 #define CHROME_BROWSER_PASSWORD_MANAGER_PASSWORD_STORE_X_H_ |
7 | 7 |
8 #include <vector> | 8 #include <vector> |
9 | 9 |
10 #include "base/memory/scoped_ptr.h" | 10 #include "base/memory/scoped_ptr.h" |
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
53 }; | 53 }; |
54 | 54 |
55 // Takes ownership of |login_db| and |backend|. |backend| may be NULL in which | 55 // Takes ownership of |login_db| and |backend|. |backend| may be NULL in which |
56 // case this PasswordStoreX will act the same as PasswordStoreDefault. | 56 // case this PasswordStoreX will act the same as PasswordStoreDefault. |
57 PasswordStoreX(LoginDatabase* login_db, | 57 PasswordStoreX(LoginDatabase* login_db, |
58 Profile* profile, | 58 Profile* profile, |
59 NativeBackend* backend); | 59 NativeBackend* backend); |
60 | 60 |
61 #if !defined(OS_MACOSX) && !defined(OS_CHROMEOS) && defined(OS_POSIX) | 61 #if !defined(OS_MACOSX) && !defined(OS_CHROMEOS) && defined(OS_POSIX) |
62 // Registers the pref setting used for the methods below. | 62 // Registers the pref setting used for the methods below. |
63 static void RegisterUserPrefs(user_prefs::PrefRegistrySyncable* registry); | 63 static void RegisterProfilePrefs(user_prefs::PrefRegistrySyncable* registry); |
64 | 64 |
65 // Returns true if passwords have been tagged with the local profile id. | 65 // Returns true if passwords have been tagged with the local profile id. |
66 static bool PasswordsUseLocalProfileId(PrefService* prefs); | 66 static bool PasswordsUseLocalProfileId(PrefService* prefs); |
67 | 67 |
68 // Sets the persistent bit indicating that passwords have been tagged with the | 68 // Sets the persistent bit indicating that passwords have been tagged with the |
69 // local profile id. This cannot be unset; passwords get migrated only once. | 69 // local profile id. This cannot be unset; passwords get migrated only once. |
70 // The caller promises that |prefs| will not be deleted any time soon. | 70 // The caller promises that |prefs| will not be deleted any time soon. |
71 static void SetPasswordsUseLocalProfileId(PrefService* prefs); | 71 static void SetPasswordsUseLocalProfileId(PrefService* prefs); |
72 #endif // !defined(OS_MACOSX) && !defined(OS_CHROMEOS) && defined(OS_POSIX) | 72 #endif // !defined(OS_MACOSX) && !defined(OS_CHROMEOS) && defined(OS_POSIX) |
73 | 73 |
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
120 // Whether we should allow falling back to the default store. If there is | 120 // Whether we should allow falling back to the default store. If there is |
121 // nothing to migrate, then the first attempt to use the native store will | 121 // nothing to migrate, then the first attempt to use the native store will |
122 // be the first time we try to use it and we should allow falling back. If | 122 // be the first time we try to use it and we should allow falling back. If |
123 // we have migrated successfully, then we do not allow falling back. | 123 // we have migrated successfully, then we do not allow falling back. |
124 bool allow_fallback_; | 124 bool allow_fallback_; |
125 | 125 |
126 DISALLOW_COPY_AND_ASSIGN(PasswordStoreX); | 126 DISALLOW_COPY_AND_ASSIGN(PasswordStoreX); |
127 }; | 127 }; |
128 | 128 |
129 #endif // CHROME_BROWSER_PASSWORD_MANAGER_PASSWORD_STORE_X_H_ | 129 #endif // CHROME_BROWSER_PASSWORD_MANAGER_PASSWORD_STORE_X_H_ |
OLD | NEW |