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

Side by Side Diff: content/browser/renderer_host/media/video_capture_manager.cc

Issue 702703002: Revert of Win Video Capture: Create an STA |video_capture_thread_| from MediaStreamManager. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 1 month 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 | « content/browser/renderer_host/media/media_stream_manager.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 "content/browser/renderer_host/media/video_capture_manager.h" 5 #include "content/browser/renderer_host/media/video_capture_manager.h"
6 6
7 #include <set> 7 #include <set>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/bind_helpers.h" 10 #include "base/bind_helpers.h"
(...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after
125 const scoped_refptr<base::SingleThreadTaskRunner>& device_task_runner) { 125 const scoped_refptr<base::SingleThreadTaskRunner>& device_task_runner) {
126 DCHECK_CURRENTLY_ON(BrowserThread::IO); 126 DCHECK_CURRENTLY_ON(BrowserThread::IO);
127 DCHECK(!listener_); 127 DCHECK(!listener_);
128 DCHECK(!device_task_runner_.get()); 128 DCHECK(!device_task_runner_.get());
129 listener_ = listener; 129 listener_ = listener;
130 device_task_runner_ = device_task_runner; 130 device_task_runner_ = device_task_runner;
131 } 131 }
132 132
133 void VideoCaptureManager::Unregister() { 133 void VideoCaptureManager::Unregister() {
134 DCHECK(listener_); 134 DCHECK(listener_);
135 DCHECK(device_task_runner_.get());
136 listener_ = NULL; 135 listener_ = NULL;
137 device_task_runner_ = NULL;
138 } 136 }
139 137
140 void VideoCaptureManager::EnumerateDevices(MediaStreamType stream_type) { 138 void VideoCaptureManager::EnumerateDevices(MediaStreamType stream_type) {
141 DCHECK_CURRENTLY_ON(BrowserThread::IO); 139 DCHECK_CURRENTLY_ON(BrowserThread::IO);
142 DVLOG(1) << "VideoCaptureManager::EnumerateDevices, type " << stream_type; 140 DVLOG(1) << "VideoCaptureManager::EnumerateDevices, type " << stream_type;
143 DCHECK(listener_); 141 DCHECK(listener_);
144 DCHECK_EQ(stream_type, MEDIA_DEVICE_VIDEO_CAPTURE); 142 DCHECK_EQ(stream_type, MEDIA_DEVICE_VIDEO_CAPTURE);
145 143
146 // Bind a callback to ConsolidateDevicesInfoOnDeviceThread() with an argument 144 // Bind a callback to ConsolidateDevicesInfoOnDeviceThread() with an argument
147 // for another callback to OnDevicesInfoEnumerated() to be run in the current 145 // for another callback to OnDevicesInfoEnumerated() to be run in the current
(...skipping 574 matching lines...) Expand 10 before | Expand all | Expand 10 after
722 gfx::NativeViewId window_id) { 720 gfx::NativeViewId window_id) {
723 DCHECK(IsOnDeviceThread()); 721 DCHECK(IsOnDeviceThread());
724 DCHECK(notification_window_ids_.find(session_id) == 722 DCHECK(notification_window_ids_.find(session_id) ==
725 notification_window_ids_.end()); 723 notification_window_ids_.end());
726 notification_window_ids_[session_id] = window_id; 724 notification_window_ids_[session_id] = window_id;
727 VLOG(2) << "Screen capture notification window saved for session " 725 VLOG(2) << "Screen capture notification window saved for session "
728 << session_id << " on device thread."; 726 << session_id << " on device thread.";
729 } 727 }
730 728
731 } // namespace content 729 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/renderer_host/media/media_stream_manager.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698