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

Side by Side Diff: chrome/browser/password_manager/simple_password_store_mac.h

Issue 1858513002: chrome/browser/password_manager: scoped_ptr -> unique_ptr (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix Windows -- revert unwanted change Created 4 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 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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_SIMPLE_PASSWORD_STORE_MAC_H_ 5 #ifndef CHROME_BROWSER_PASSWORD_MANAGER_SIMPLE_PASSWORD_STORE_MAC_H_
6 #define CHROME_BROWSER_PASSWORD_MANAGER_SIMPLE_PASSWORD_STORE_MAC_H_ 6 #define CHROME_BROWSER_PASSWORD_MANAGER_SIMPLE_PASSWORD_STORE_MAC_H_
7 7
8 #include "base/macros.h" 8 #include "base/macros.h"
9 #include "components/password_manager/core/browser/password_store_default.h" 9 #include "components/password_manager/core/browser/password_store_default.h"
10 10
11 // The same as PasswordStoreDefault but running on the dedicated thread. The 11 // The same as PasswordStoreDefault but running on the dedicated thread. The
12 // owner is responsible for the thread lifetime. 12 // owner is responsible for the thread lifetime.
13 class SimplePasswordStoreMac : public password_manager::PasswordStoreDefault { 13 class SimplePasswordStoreMac : public password_manager::PasswordStoreDefault {
14 public: 14 public:
15 // Passes the arguments to PasswordStoreDefault. |background_task_runner| and 15 // Passes the arguments to PasswordStoreDefault. |background_task_runner| and
16 // |login_db| can be overwritten later in InitWithTaskRunner(). 16 // |login_db| can be overwritten later in InitWithTaskRunner().
17 SimplePasswordStoreMac( 17 SimplePasswordStoreMac(
18 scoped_refptr<base::SingleThreadTaskRunner> main_thread_runner, 18 scoped_refptr<base::SingleThreadTaskRunner> main_thread_runner,
19 scoped_refptr<base::SingleThreadTaskRunner> background_thread_runner, 19 scoped_refptr<base::SingleThreadTaskRunner> background_thread_runner,
20 scoped_ptr<password_manager::LoginDatabase> login_db); 20 std::unique_ptr<password_manager::LoginDatabase> login_db);
21 21
22 // Sets the background thread and LoginDatabase. |login_db| should be already 22 // Sets the background thread and LoginDatabase. |login_db| should be already
23 // inited. The method isn't necessary to call if the constructor already got 23 // inited. The method isn't necessary to call if the constructor already got
24 // the correct parameters. 24 // the correct parameters.
25 void InitWithTaskRunner( 25 void InitWithTaskRunner(
26 scoped_refptr<base::SingleThreadTaskRunner> background_task_runner, 26 scoped_refptr<base::SingleThreadTaskRunner> background_task_runner,
27 scoped_ptr<password_manager::LoginDatabase> login_db); 27 std::unique_ptr<password_manager::LoginDatabase> login_db);
28 28
29 using PasswordStoreDefault::GetBackgroundTaskRunner; 29 using PasswordStoreDefault::GetBackgroundTaskRunner;
30 30
31 protected: 31 protected:
32 ~SimplePasswordStoreMac() override; 32 ~SimplePasswordStoreMac() override;
33 33
34 private: 34 private:
35 bool Init(const syncer::SyncableService::StartSyncFlare& flare) override; 35 bool Init(const syncer::SyncableService::StartSyncFlare& flare) override;
36 36
37 DISALLOW_COPY_AND_ASSIGN(SimplePasswordStoreMac); 37 DISALLOW_COPY_AND_ASSIGN(SimplePasswordStoreMac);
38 }; 38 };
39 39
40 #endif // CHROME_BROWSER_PASSWORD_MANAGER_SIMPLE_PASSWORD_STORE_MAC_H_ 40 #endif // CHROME_BROWSER_PASSWORD_MANAGER_SIMPLE_PASSWORD_STORE_MAC_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698