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

Side by Side Diff: chrome/browser/media/media_capture_devices_dispatcher.cc

Issue 483523006: Check all settings when checking mic and camera access (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 4 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 "chrome/browser/media/media_capture_devices_dispatcher.h" 5 #include "chrome/browser/media/media_capture_devices_dispatcher.h"
6 6
7 #include "apps/app_window.h" 7 #include "apps/app_window.h"
8 #include "apps/app_window_registry.h" 8 #include "apps/app_window_registry.h"
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/logging.h" 10 #include "base/logging.h"
(...skipping 322 matching lines...) Expand 10 before | Expand all | Expand 10 after
333 } 333 }
334 } 334 }
335 335
336 void MediaCaptureDevicesDispatcher::ProcessMediaAccessRequest( 336 void MediaCaptureDevicesDispatcher::ProcessMediaAccessRequest(
337 content::WebContents* web_contents, 337 content::WebContents* web_contents,
338 const content::MediaStreamRequest& request, 338 const content::MediaStreamRequest& request,
339 const content::MediaResponseCallback& callback, 339 const content::MediaResponseCallback& callback,
340 const extensions::Extension* extension) { 340 const extensions::Extension* extension) {
341 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); 341 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI));
342 342
343 NOTREACHED();
344
343 if (request.video_type == content::MEDIA_DESKTOP_VIDEO_CAPTURE || 345 if (request.video_type == content::MEDIA_DESKTOP_VIDEO_CAPTURE ||
344 request.audio_type == content::MEDIA_LOOPBACK_AUDIO_CAPTURE) { 346 request.audio_type == content::MEDIA_LOOPBACK_AUDIO_CAPTURE) {
345 ProcessDesktopCaptureAccessRequest( 347 ProcessDesktopCaptureAccessRequest(
346 web_contents, request, callback, extension); 348 web_contents, request, callback, extension);
347 } else if (request.video_type == content::MEDIA_TAB_VIDEO_CAPTURE || 349 } else if (request.video_type == content::MEDIA_TAB_VIDEO_CAPTURE ||
348 request.audio_type == content::MEDIA_TAB_AUDIO_CAPTURE) { 350 request.audio_type == content::MEDIA_TAB_AUDIO_CAPTURE) {
349 ProcessTabCaptureAccessRequest( 351 ProcessTabCaptureAccessRequest(
350 web_contents, request, callback, extension); 352 web_contents, request, callback, extension);
351 } else if (extension && (extension->is_platform_app() || 353 } else if (extension && (extension->is_platform_app() ||
352 IsMediaRequestWhitelistedForExtension(extension))) { 354 IsMediaRequestWhitelistedForExtension(extension))) {
(...skipping 649 matching lines...) Expand 10 before | Expand all | Expand 10 after
1002 1004
1003 void MediaCaptureDevicesDispatcher::SetTestAudioCaptureDevices( 1005 void MediaCaptureDevicesDispatcher::SetTestAudioCaptureDevices(
1004 const MediaStreamDevices& devices) { 1006 const MediaStreamDevices& devices) {
1005 test_audio_devices_ = devices; 1007 test_audio_devices_ = devices;
1006 } 1008 }
1007 1009
1008 void MediaCaptureDevicesDispatcher::SetTestVideoCaptureDevices( 1010 void MediaCaptureDevicesDispatcher::SetTestVideoCaptureDevices(
1009 const MediaStreamDevices& devices) { 1011 const MediaStreamDevices& devices) {
1010 test_video_devices_ = devices; 1012 test_video_devices_ = devices;
1011 } 1013 }
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/ui/browser.h » ('j') | content/browser/frame_host/render_frame_host_delegate.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698