OLD | NEW |
---|---|
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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_PERMISSIONS_PERMISSION_CONTEXT_BASE_H_ | 5 #ifndef CHROME_BROWSER_PERMISSIONS_PERMISSION_CONTEXT_BASE_H_ |
6 #define CHROME_BROWSER_PERMISSIONS_PERMISSION_CONTEXT_BASE_H_ | 6 #define CHROME_BROWSER_PERMISSIONS_PERMISSION_CONTEXT_BASE_H_ |
7 | 7 |
8 #include <memory> | 8 #include <memory> |
9 #include <unordered_map> | 9 #include <unordered_map> |
10 | 10 |
(...skipping 163 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
174 // Browsing. |permission_blocked| determines whether to auto-block the | 174 // Browsing. |permission_blocked| determines whether to auto-block the |
175 // permission request without prompting the user for a decision. | 175 // permission request without prompting the user for a decision. |
176 void ContinueRequestPermission(content::WebContents* web_contents, | 176 void ContinueRequestPermission(content::WebContents* web_contents, |
177 const PermissionRequestID& id, | 177 const PermissionRequestID& id, |
178 const GURL& requesting_origin, | 178 const GURL& requesting_origin, |
179 const GURL& embedding_origin, | 179 const GURL& embedding_origin, |
180 bool user_gesture, | 180 bool user_gesture, |
181 const BrowserPermissionCallback& callback, | 181 const BrowserPermissionCallback& callback, |
182 bool permission_blocked); | 182 bool permission_blocked); |
183 | 183 |
184 void SetSafeBrowsingDatabaseManagerAndTimeoutForTest( | |
185 scoped_refptr<safe_browsing::SafeBrowsingDatabaseManager> db_manager, | |
186 int timeout); | |
187 | |
188 Profile* profile_; | 184 Profile* profile_; |
189 const content::PermissionType permission_type_; | 185 const content::PermissionType permission_type_; |
190 const ContentSettingsType content_settings_type_; | 186 const ContentSettingsType content_settings_type_; |
191 int safe_browsing_timeout_; | 187 int safe_browsing_timeout_; |
dominickn
2017/01/20 04:03:47
Remove?
meredithl
2017/01/20 04:21:33
Done.
| |
192 scoped_refptr<safe_browsing::SafeBrowsingDatabaseManager> db_manager_; | 188 scoped_refptr<safe_browsing::SafeBrowsingDatabaseManager> db_manager_; |
dominickn
2017/01/20 04:03:47
Remove?
meredithl
2017/01/20 04:21:33
Done.
| |
193 #if defined(OS_ANDROID) | 189 #if defined(OS_ANDROID) |
194 std::unique_ptr<PermissionQueueController> permission_queue_controller_; | 190 std::unique_ptr<PermissionQueueController> permission_queue_controller_; |
195 #endif | 191 #endif |
196 std::unordered_map<std::string, std::unique_ptr<PermissionRequest>> | 192 std::unordered_map<std::string, std::unique_ptr<PermissionRequest>> |
197 pending_requests_; | 193 pending_requests_; |
198 | 194 |
199 // Must be the last member, to ensure that it will be | 195 // Must be the last member, to ensure that it will be |
200 // destroyed first, which will invalidate weak pointers | 196 // destroyed first, which will invalidate weak pointers |
201 base::WeakPtrFactory<PermissionContextBase> weak_factory_; | 197 base::WeakPtrFactory<PermissionContextBase> weak_factory_; |
202 }; | 198 }; |
203 | 199 |
204 #endif // CHROME_BROWSER_PERMISSIONS_PERMISSION_CONTEXT_BASE_H_ | 200 #endif // CHROME_BROWSER_PERMISSIONS_PERMISSION_CONTEXT_BASE_H_ |
OLD | NEW |