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

Side by Side Diff: chrome/browser/ui/crypto_module_delegate_nss.h

Issue 1865213004: Convert //chrome/browser/ui from scoped_ptr to std::unique_ptr (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase 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 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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_UI_CRYPTO_MODULE_DELEGATE_NSS_H_ 5 #ifndef CHROME_BROWSER_UI_CRYPTO_MODULE_DELEGATE_NSS_H_
6 #define CHROME_BROWSER_UI_CRYPTO_MODULE_DELEGATE_NSS_H_ 6 #define CHROME_BROWSER_UI_CRYPTO_MODULE_DELEGATE_NSS_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/compiler_specific.h" 10 #include "base/compiler_specific.h"
(...skipping 22 matching lines...) Expand all
33 33
34 ~ChromeNSSCryptoModuleDelegate() override; 34 ~ChromeNSSCryptoModuleDelegate() override;
35 35
36 // Must be called on IO thread. Creates a delegate and returns it 36 // Must be called on IO thread. Creates a delegate and returns it
37 // synchronously or asynchronously to |callback|. If the delegate could not be 37 // synchronously or asynchronously to |callback|. If the delegate could not be
38 // created, |callback| is called with NULL. 38 // created, |callback| is called with NULL.
39 static void CreateForResourceContext( 39 static void CreateForResourceContext(
40 chrome::CryptoModulePasswordReason reason, 40 chrome::CryptoModulePasswordReason reason,
41 const net::HostPortPair& server, 41 const net::HostPortPair& server,
42 content::ResourceContext* context, 42 content::ResourceContext* context,
43 const base::Callback<void(scoped_ptr<ChromeNSSCryptoModuleDelegate>)>& 43 const base::Callback<
44 callback); 44 void(std::unique_ptr<ChromeNSSCryptoModuleDelegate>)>& callback);
45 45
46 // crypto::NSSCryptoModuleDelegate implementation. 46 // crypto::NSSCryptoModuleDelegate implementation.
47 crypto::ScopedPK11Slot RequestSlot() override; 47 crypto::ScopedPK11Slot RequestSlot() override;
48 48
49 // crypto::CryptoModuleBlockingPasswordDelegate implementation. 49 // crypto::CryptoModuleBlockingPasswordDelegate implementation.
50 std::string RequestPassword(const std::string& slot_name, 50 std::string RequestPassword(const std::string& slot_name,
51 bool retry, 51 bool retry,
52 bool* cancelled) override; 52 bool* cancelled) override;
53 53
54 private: 54 private:
(...skipping 18 matching lines...) Expand all
73 DISALLOW_COPY_AND_ASSIGN(ChromeNSSCryptoModuleDelegate); 73 DISALLOW_COPY_AND_ASSIGN(ChromeNSSCryptoModuleDelegate);
74 }; 74 };
75 75
76 // Create a delegate which only handles unlocking slots. 76 // Create a delegate which only handles unlocking slots.
77 crypto::CryptoModuleBlockingPasswordDelegate* 77 crypto::CryptoModuleBlockingPasswordDelegate*
78 CreateCryptoModuleBlockingPasswordDelegate( 78 CreateCryptoModuleBlockingPasswordDelegate(
79 chrome::CryptoModulePasswordReason reason, 79 chrome::CryptoModulePasswordReason reason,
80 const net::HostPortPair& server); 80 const net::HostPortPair& server);
81 81
82 #endif // CHROME_BROWSER_UI_CRYPTO_MODULE_DELEGATE_NSS_H_ 82 #endif // CHROME_BROWSER_UI_CRYPTO_MODULE_DELEGATE_NSS_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698