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 #include "extensions/shell/browser/shell_extension_host_delegate.h" | 5 #include "extensions/shell/browser/shell_extension_host_delegate.h" |
6 | 6 |
7 #include "base/logging.h" | 7 #include "base/logging.h" |
8 #include "extensions/shell/browser/media_capture_util.h" | 8 #include "extensions/shell/browser/media_capture_util.h" |
9 #include "extensions/shell/browser/shell_extension_web_contents_observer.h" | 9 #include "extensions/shell/browser/shell_extension_web_contents_observer.h" |
10 | 10 |
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
45 void ShellExtensionHostDelegate::ProcessMediaAccessRequest( | 45 void ShellExtensionHostDelegate::ProcessMediaAccessRequest( |
46 content::WebContents* web_contents, | 46 content::WebContents* web_contents, |
47 const content::MediaStreamRequest& request, | 47 const content::MediaStreamRequest& request, |
48 const content::MediaResponseCallback& callback, | 48 const content::MediaResponseCallback& callback, |
49 const Extension* extension) { | 49 const Extension* extension) { |
50 // Allow access to the microphone and/or camera. | 50 // Allow access to the microphone and/or camera. |
51 media_capture_util::GrantMediaStreamRequest( | 51 media_capture_util::GrantMediaStreamRequest( |
52 web_contents, request, callback, extension); | 52 web_contents, request, callback, extension); |
53 } | 53 } |
54 | 54 |
| 55 bool ShellExtensionHostDelegate::CheckMediaAccessPermission( |
| 56 content::WebContents* web_contents, |
| 57 const GURL& security_origin, |
| 58 content::MediaStreamType type, |
| 59 const Extension* extension) { |
| 60 media_capture_util::VerifyMediaAccessPermission(type, extension); |
| 61 return true; |
| 62 } |
| 63 |
55 } // namespace extensions | 64 } // namespace extensions |
56 | |
OLD | NEW |