OLD | NEW |
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 CONTENT_SHELL_BROWSER_SHELL_CONTENT_BROWSER_CLIENT_H_ | 5 #ifndef CONTENT_SHELL_BROWSER_SHELL_CONTENT_BROWSER_CLIENT_H_ |
6 #define CONTENT_SHELL_BROWSER_SHELL_CONTENT_BROWSER_CLIENT_H_ | 6 #define CONTENT_SHELL_BROWSER_SHELL_CONTENT_BROWSER_CLIENT_H_ |
7 | 7 |
| 8 #include <memory> |
8 #include <string> | 9 #include <string> |
9 | 10 |
10 #include "base/compiler_specific.h" | 11 #include "base/compiler_specific.h" |
11 #include "base/files/file_path.h" | 12 #include "base/files/file_path.h" |
12 #include "base/memory/scoped_ptr.h" | |
13 #include "build/build_config.h" | 13 #include "build/build_config.h" |
14 #include "content/public/browser/content_browser_client.h" | 14 #include "content/public/browser/content_browser_client.h" |
15 #include "content/shell/browser/shell_resource_dispatcher_host_delegate.h" | 15 #include "content/shell/browser/shell_resource_dispatcher_host_delegate.h" |
16 #include "content/shell/browser/shell_speech_recognition_manager_delegate.h" | 16 #include "content/shell/browser/shell_speech_recognition_manager_delegate.h" |
17 | 17 |
18 namespace content { | 18 namespace content { |
19 | 19 |
20 class ShellBrowserContext; | 20 class ShellBrowserContext; |
21 class ShellBrowserMainParts; | 21 class ShellBrowserMainParts; |
22 | 22 |
(...skipping 21 matching lines...) Expand all Loading... |
44 int child_process_id) override; | 44 int child_process_id) override; |
45 void ResourceDispatcherHostCreated() override; | 45 void ResourceDispatcherHostCreated() override; |
46 AccessTokenStore* CreateAccessTokenStore() override; | 46 AccessTokenStore* CreateAccessTokenStore() override; |
47 std::string GetDefaultDownloadName() override; | 47 std::string GetDefaultDownloadName() override; |
48 WebContentsViewDelegate* GetWebContentsViewDelegate( | 48 WebContentsViewDelegate* GetWebContentsViewDelegate( |
49 WebContents* web_contents) override; | 49 WebContents* web_contents) override; |
50 QuotaPermissionContext* CreateQuotaPermissionContext() override; | 50 QuotaPermissionContext* CreateQuotaPermissionContext() override; |
51 void SelectClientCertificate( | 51 void SelectClientCertificate( |
52 WebContents* web_contents, | 52 WebContents* web_contents, |
53 net::SSLCertRequestInfo* cert_request_info, | 53 net::SSLCertRequestInfo* cert_request_info, |
54 scoped_ptr<ClientCertificateDelegate> delegate) override; | 54 std::unique_ptr<ClientCertificateDelegate> delegate) override; |
55 | 55 |
56 SpeechRecognitionManagerDelegate* CreateSpeechRecognitionManagerDelegate() | 56 SpeechRecognitionManagerDelegate* CreateSpeechRecognitionManagerDelegate() |
57 override; | 57 override; |
58 net::NetLog* GetNetLog() override; | 58 net::NetLog* GetNetLog() override; |
59 bool ShouldSwapProcessesForRedirect(ResourceContext* resource_context, | 59 bool ShouldSwapProcessesForRedirect(ResourceContext* resource_context, |
60 const GURL& current_url, | 60 const GURL& current_url, |
61 const GURL& new_url) override; | 61 const GURL& new_url) override; |
62 DevToolsManagerDelegate* GetDevToolsManagerDelegate() override; | 62 DevToolsManagerDelegate* GetDevToolsManagerDelegate() override; |
63 | 63 |
64 void OpenURL(BrowserContext* browser_context, | 64 void OpenURL(BrowserContext* browser_context, |
(...skipping 26 matching lines...) Expand all Loading... |
91 } | 91 } |
92 | 92 |
93 // Used for content_browsertests. | 93 // Used for content_browsertests. |
94 void set_select_client_certificate_callback( | 94 void set_select_client_certificate_callback( |
95 base::Closure select_client_certificate_callback) { | 95 base::Closure select_client_certificate_callback) { |
96 select_client_certificate_callback_ = select_client_certificate_callback; | 96 select_client_certificate_callback_ = select_client_certificate_callback; |
97 } | 97 } |
98 | 98 |
99 protected: | 99 protected: |
100 void set_resource_dispatcher_host_delegate( | 100 void set_resource_dispatcher_host_delegate( |
101 scoped_ptr<ShellResourceDispatcherHostDelegate> delegate) { | 101 std::unique_ptr<ShellResourceDispatcherHostDelegate> delegate) { |
102 resource_dispatcher_host_delegate_ = std::move(delegate); | 102 resource_dispatcher_host_delegate_ = std::move(delegate); |
103 } | 103 } |
104 | 104 |
105 void set_browser_main_parts(ShellBrowserMainParts* parts) { | 105 void set_browser_main_parts(ShellBrowserMainParts* parts) { |
106 shell_browser_main_parts_ = parts; | 106 shell_browser_main_parts_ = parts; |
107 } | 107 } |
108 | 108 |
109 private: | 109 private: |
110 | 110 std::unique_ptr<ShellResourceDispatcherHostDelegate> |
111 scoped_ptr<ShellResourceDispatcherHostDelegate> | |
112 resource_dispatcher_host_delegate_; | 111 resource_dispatcher_host_delegate_; |
113 | 112 |
114 base::Closure select_client_certificate_callback_; | 113 base::Closure select_client_certificate_callback_; |
115 | 114 |
116 ShellBrowserMainParts* shell_browser_main_parts_; | 115 ShellBrowserMainParts* shell_browser_main_parts_; |
117 }; | 116 }; |
118 | 117 |
119 } // namespace content | 118 } // namespace content |
120 | 119 |
121 #endif // CONTENT_SHELL_BROWSER_SHELL_CONTENT_BROWSER_CLIENT_H_ | 120 #endif // CONTENT_SHELL_BROWSER_SHELL_CONTENT_BROWSER_CLIENT_H_ |
OLD | NEW |