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_MAC_H_ | 5 #ifndef CHROME_BROWSER_PASSWORD_MANAGER_PASSWORD_STORE_MAC_H_ |
6 #define CHROME_BROWSER_PASSWORD_MANAGER_PASSWORD_STORE_MAC_H_ | 6 #define CHROME_BROWSER_PASSWORD_MANAGER_PASSWORD_STORE_MAC_H_ |
7 | 7 |
8 #include <vector> | 8 #include <vector> |
9 | 9 |
10 #include "base/callback_forward.h" | 10 #include "base/callback_forward.h" |
(...skipping 20 matching lines...) Expand all Loading... |
31 // Takes ownership of |keychain| and |login_db|, both of which must be | 31 // Takes ownership of |keychain| and |login_db|, both of which must be |
32 // non-NULL. | 32 // non-NULL. |
33 PasswordStoreMac( | 33 PasswordStoreMac( |
34 scoped_refptr<base::SingleThreadTaskRunner> main_thread_runner, | 34 scoped_refptr<base::SingleThreadTaskRunner> main_thread_runner, |
35 scoped_refptr<base::SingleThreadTaskRunner> db_thread_runner, | 35 scoped_refptr<base::SingleThreadTaskRunner> db_thread_runner, |
36 crypto::AppleKeychain* keychain, | 36 crypto::AppleKeychain* keychain, |
37 password_manager::LoginDatabase* login_db); | 37 password_manager::LoginDatabase* login_db); |
38 | 38 |
39 // Initializes |thread_|. | 39 // Initializes |thread_|. |
40 virtual bool Init( | 40 virtual bool Init( |
41 const syncer::SyncableService::StartSyncFlare& flare) OVERRIDE; | 41 const syncer::SyncableService::StartSyncFlare& flare, |
| 42 const std::string& sync_username) OVERRIDE; |
42 | 43 |
43 // Stops |thread_|. | 44 // Stops |thread_|. |
44 virtual void Shutdown() OVERRIDE; | 45 virtual void Shutdown() OVERRIDE; |
45 | 46 |
46 protected: | 47 protected: |
47 virtual ~PasswordStoreMac(); | 48 virtual ~PasswordStoreMac(); |
48 | 49 |
49 virtual scoped_refptr<base::SingleThreadTaskRunner> | 50 virtual scoped_refptr<base::SingleThreadTaskRunner> |
50 GetBackgroundTaskRunner() OVERRIDE; | 51 GetBackgroundTaskRunner() OVERRIDE; |
51 | 52 |
52 private: | 53 private: |
53 virtual void ReportMetricsImpl() OVERRIDE; | 54 virtual void ReportMetricsImpl(const std::string& sync_username) OVERRIDE; |
54 virtual password_manager::PasswordStoreChangeList AddLoginImpl( | 55 virtual password_manager::PasswordStoreChangeList AddLoginImpl( |
55 const autofill::PasswordForm& form) OVERRIDE; | 56 const autofill::PasswordForm& form) OVERRIDE; |
56 virtual password_manager::PasswordStoreChangeList UpdateLoginImpl( | 57 virtual password_manager::PasswordStoreChangeList UpdateLoginImpl( |
57 const autofill::PasswordForm& form) OVERRIDE; | 58 const autofill::PasswordForm& form) OVERRIDE; |
58 virtual password_manager::PasswordStoreChangeList RemoveLoginImpl( | 59 virtual password_manager::PasswordStoreChangeList RemoveLoginImpl( |
59 const autofill::PasswordForm& form) OVERRIDE; | 60 const autofill::PasswordForm& form) OVERRIDE; |
60 virtual password_manager::PasswordStoreChangeList | 61 virtual password_manager::PasswordStoreChangeList |
61 RemoveLoginsCreatedBetweenImpl(base::Time delete_begin, | 62 RemoveLoginsCreatedBetweenImpl(base::Time delete_begin, |
62 base::Time delete_end) OVERRIDE; | 63 base::Time delete_end) OVERRIDE; |
63 virtual password_manager::PasswordStoreChangeList | 64 virtual password_manager::PasswordStoreChangeList |
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
95 scoped_ptr<crypto::AppleKeychain> keychain_; | 96 scoped_ptr<crypto::AppleKeychain> keychain_; |
96 scoped_ptr<password_manager::LoginDatabase> login_metadata_db_; | 97 scoped_ptr<password_manager::LoginDatabase> login_metadata_db_; |
97 | 98 |
98 // Thread that the synchronous methods are run on. | 99 // Thread that the synchronous methods are run on. |
99 scoped_ptr<base::Thread> thread_; | 100 scoped_ptr<base::Thread> thread_; |
100 | 101 |
101 DISALLOW_COPY_AND_ASSIGN(PasswordStoreMac); | 102 DISALLOW_COPY_AND_ASSIGN(PasswordStoreMac); |
102 }; | 103 }; |
103 | 104 |
104 #endif // CHROME_BROWSER_PASSWORD_MANAGER_PASSWORD_STORE_MAC_H_ | 105 #endif // CHROME_BROWSER_PASSWORD_MANAGER_PASSWORD_STORE_MAC_H_ |
OLD | NEW |