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

Unified Diff: content/browser/renderer_host/media/video_capture_host.cc

Issue 2753073006: [Mojo Video Capture] Add support to BuildableVideoCaptureDevice for aborting the device start. (Closed)
Patch Set: Created 3 years, 9 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 side-by-side diff with in-line comments
Download patch
Index: content/browser/renderer_host/media/video_capture_host.cc
diff --git a/content/browser/renderer_host/media/video_capture_host.cc b/content/browser/renderer_host/media/video_capture_host.cc
index 3f23cf69d4ba55a5961785ea1c10238db2632a8f..8da0fd61d2c58c95e206e0b71e5fbd62ec0f661a 100644
--- a/content/browser/renderer_host/media/video_capture_host.cc
+++ b/content/browser/renderer_host/media/video_capture_host.cc
@@ -39,7 +39,7 @@ VideoCaptureHost::~VideoCaptureHost() {
const base::WeakPtr<VideoCaptureController>& controller = it->second;
if (controller) {
const VideoCaptureControllerID controller_id(it->first);
- media_stream_manager_->video_capture_manager()->StopCaptureForClient(
+ media_stream_manager_->video_capture_manager()->DisconnectClient(
controller.get(), controller_id, this, false);
++it;
} else {
@@ -142,7 +142,7 @@ void VideoCaptureHost::Start(int32_t device_id,
}
controllers_[controller_id] = base::WeakPtr<VideoCaptureController>();
- media_stream_manager_->video_capture_manager()->StartCaptureForClient(
+ media_stream_manager_->video_capture_manager()->ConnectClient(
session_id, params, controller_id, this,
base::Bind(&VideoCaptureHost::OnControllerAdded,
weak_factory_.GetWeakPtr(), device_id));
@@ -295,7 +295,7 @@ void VideoCaptureHost::OnControllerAdded(
auto it = controllers_.find(controller_id);
if (it == controllers_.end()) {
if (controller) {
- media_stream_manager_->video_capture_manager()->StopCaptureForClient(
+ media_stream_manager_->video_capture_manager()->DisconnectClient(
controller.get(), controller_id, this, false);
}
return;
@@ -327,7 +327,7 @@ void VideoCaptureHost::DeleteVideoCaptureController(
if (!controller)
return;
- media_stream_manager_->video_capture_manager()->StopCaptureForClient(
+ media_stream_manager_->video_capture_manager()->DisconnectClient(
controller.get(), controller_id, this, on_error);
}

Powered by Google App Engine
This is Rietveld 408576698