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

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

Issue 1873293002: Report if video capturing meets output protection requirement. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Addressed oshima and nasko's comments, and rebased. Created 4 years, 7 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
« no previous file with comments | « chrome/browser/media/tab_capture_access_handler.h ('k') | chrome/chrome_browser.gypi » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 "chrome/browser/media/tab_capture_access_handler.h" 5 #include "chrome/browser/media/tab_capture_access_handler.h"
6 6
7 #include <utility> 7 #include <utility>
8 8
9 #include "chrome/browser/extensions/api/tab_capture/tab_capture_registry.h" 9 #include "chrome/browser/extensions/api/tab_capture/tab_capture_registry.h"
10 #include "chrome/browser/media/media_capture_devices_dispatcher.h" 10 #include "chrome/browser/media/media_capture_devices_dispatcher.h"
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after
72 extensions::APIPermission::kTabCapture)) { 72 extensions::APIPermission::kTabCapture)) {
73 devices.push_back(content::MediaStreamDevice( 73 devices.push_back(content::MediaStreamDevice(
74 content::MEDIA_TAB_VIDEO_CAPTURE, std::string(), std::string())); 74 content::MEDIA_TAB_VIDEO_CAPTURE, std::string(), std::string()));
75 } 75 }
76 76
77 if (!devices.empty()) { 77 if (!devices.empty()) {
78 ui = MediaCaptureDevicesDispatcher::GetInstance() 78 ui = MediaCaptureDevicesDispatcher::GetInstance()
79 ->GetMediaStreamCaptureIndicator() 79 ->GetMediaStreamCaptureIndicator()
80 ->RegisterMediaStream(web_contents, devices); 80 ->RegisterMediaStream(web_contents, devices);
81 } 81 }
82 UpdateExtensionTrusted(request, extension);
82 callback.Run(devices, devices.empty() ? content::MEDIA_DEVICE_INVALID_STATE 83 callback.Run(devices, devices.empty() ? content::MEDIA_DEVICE_INVALID_STATE
83 : content::MEDIA_DEVICE_OK, 84 : content::MEDIA_DEVICE_OK,
84 std::move(ui)); 85 std::move(ui));
85 } 86 }
OLDNEW
« no previous file with comments | « chrome/browser/media/tab_capture_access_handler.h ('k') | chrome/chrome_browser.gypi » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698