| Index: content/browser/renderer_host/media/video_capture_manager.cc
|
| diff --git a/content/browser/renderer_host/media/video_capture_manager.cc b/content/browser/renderer_host/media/video_capture_manager.cc
|
| index 71af3fc9bfa6a98e306d9171edf53a9a6dcfcaee..83b01a7fb1a2c30734bcc2c8dda5104ea9135a14 100644
|
| --- a/content/browser/renderer_host/media/video_capture_manager.cc
|
| +++ b/content/browser/renderer_host/media/video_capture_manager.cc
|
| @@ -263,6 +263,8 @@ void VideoCaptureManager::DoStartDeviceOnDeviceThread(
|
| notification_window_ids_.end()) {
|
| static_cast<DesktopCaptureDevice*>(video_capture_device.get())
|
| ->SetNotificationWindowId(notification_window_ids_[session_id]);
|
| + VLOG(2) << "Screen capture notification window passed for session "
|
| + << session_id;
|
| }
|
| }
|
| #endif // defined(ENABLE_SCREEN_CAPTURE)
|
| @@ -410,8 +412,11 @@ void VideoCaptureManager::SetDesktopCaptureWindowId(
|
| media::VideoCaptureSessionId session_id,
|
| gfx::NativeViewId window_id) {
|
| DCHECK_CURRENTLY_ON(BrowserThread::IO);
|
| + VLOG(2) << "SetDesktopCaptureWindowId called for session " << session_id;
|
| +
|
| SessionMap::iterator session_it = sessions_.find(session_id);
|
| if (session_it == sessions_.end()) {
|
| + VLOG(2) << "Session not found, will save the notification window.";
|
| device_task_runner_->PostTask(
|
| FROM_HERE,
|
| base::Bind(
|
| @@ -424,13 +429,16 @@ void VideoCaptureManager::SetDesktopCaptureWindowId(
|
|
|
| DeviceEntry* const existing_device =
|
| GetDeviceEntryForMediaStreamDevice(session_it->second);
|
| - if (!existing_device)
|
| + if (!existing_device) {
|
| + VLOG(2) << "Failed to find an existing device.";
|
| return;
|
| + }
|
|
|
| DCHECK_EQ(MEDIA_DESKTOP_VIDEO_CAPTURE, existing_device->stream_type);
|
| DesktopMediaID id = DesktopMediaID::Parse(existing_device->id);
|
| if (id.type == DesktopMediaID::TYPE_NONE ||
|
| id.type == DesktopMediaID::TYPE_AURA_WINDOW) {
|
| + VLOG(2) << "Video capture device type mismatch.";
|
| return;
|
| }
|
|
|
| @@ -640,6 +648,7 @@ void VideoCaptureManager::SetDesktopCaptureWindowIdOnDeviceThread(
|
| DesktopCaptureDevice* device =
|
| static_cast<DesktopCaptureDevice*>(entry->video_capture_device.get());
|
| device->SetNotificationWindowId(window_id);
|
| + VLOG(2) << "Screen capture notification window passed on device thread.";
|
| #endif
|
| }
|
|
|
| @@ -650,6 +659,8 @@ void VideoCaptureManager::SaveDesktopCaptureWindowIdOnDeviceThread(
|
| DCHECK(notification_window_ids_.find(session_id) ==
|
| notification_window_ids_.end());
|
| notification_window_ids_[session_id] = window_id;
|
| + VLOG(2) << "Screen capture notification window saved for session "
|
| + << session_id << " on device thread.";
|
| }
|
|
|
| } // namespace content
|
|
|