OLD | NEW |
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 #include "android_webview/browser/aw_permission_manager.h" | 5 #include "android_webview/browser/aw_permission_manager.h" |
6 | 6 |
7 #include <memory> | 7 #include <memory> |
8 #include <string> | 8 #include <string> |
9 #include <utility> | 9 #include <utility> |
10 | 10 |
11 #include "android_webview/browser/aw_browser_permission_request_delegate.h" | 11 #include "android_webview/browser/aw_browser_permission_request_delegate.h" |
12 #include "base/callback.h" | 12 #include "base/callback.h" |
13 #include "base/containers/hash_tables.h" | 13 #include "base/containers/hash_tables.h" |
14 #include "base/logging.h" | 14 #include "base/logging.h" |
| 15 #include "base/memory/ptr_util.h" |
15 #include "content/public/browser/permission_type.h" | 16 #include "content/public/browser/permission_type.h" |
16 #include "content/public/browser/render_frame_host.h" | 17 #include "content/public/browser/render_frame_host.h" |
17 #include "content/public/browser/render_process_host.h" | 18 #include "content/public/browser/render_process_host.h" |
18 #include "content/public/browser/web_contents.h" | 19 #include "content/public/browser/web_contents.h" |
19 | 20 |
20 using blink::mojom::PermissionStatus; | 21 using blink::mojom::PermissionStatus; |
21 using content::PermissionType; | 22 using content::PermissionType; |
22 | 23 |
23 using RequestPermissionsCallback = | 24 using RequestPermissionsCallback = |
24 base::Callback<void(const std::vector<PermissionStatus>&)>; | 25 base::Callback<void(const std::vector<PermissionStatus>&)>; |
(...skipping 523 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
548 ->GetLastCommittedURL().GetOrigin(); | 549 ->GetLastCommittedURL().GetOrigin(); |
549 } | 550 } |
550 | 551 |
551 AwBrowserPermissionRequestDelegate* AwPermissionManager::GetDelegate( | 552 AwBrowserPermissionRequestDelegate* AwPermissionManager::GetDelegate( |
552 int render_process_id, int render_frame_id) { | 553 int render_process_id, int render_frame_id) { |
553 return AwBrowserPermissionRequestDelegate::FromID(render_process_id, | 554 return AwBrowserPermissionRequestDelegate::FromID(render_process_id, |
554 render_frame_id); | 555 render_frame_id); |
555 } | 556 } |
556 | 557 |
557 } // namespace android_webview | 558 } // namespace android_webview |
OLD | NEW |