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

Side by Side Diff: content/browser/media/capture/desktop_capture_device.cc

Issue 2673373003: getUserMeida: report device starting states (Closed)
Patch Set: address comments on PS#8 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 unified diff | Download patch
« no previous file with comments | « no previous file | content/browser/media/capture/desktop_capture_device_aura_unittest.cc » ('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 (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 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/media/capture/desktop_capture_device.h" 5 #include "content/browser/media/capture/desktop_capture_device.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 #include <stdint.h> 8 #include <stdint.h>
9 #include <string.h> 9 #include <string.h>
10 #include <utility> 10 #include <utility>
(...skipping 168 matching lines...) Expand 10 before | Expand all | Expand 10 after
179 params.requested_format.frame_size, 179 params.requested_format.frame_size,
180 params.resolution_change_policy)); 180 params.resolution_change_policy));
181 181
182 power_save_blocker_.reset(new device::PowerSaveBlocker( 182 power_save_blocker_.reset(new device::PowerSaveBlocker(
183 device::PowerSaveBlocker::kPowerSaveBlockPreventDisplaySleep, 183 device::PowerSaveBlocker::kPowerSaveBlockPreventDisplaySleep,
184 device::PowerSaveBlocker::kReasonOther, "DesktopCaptureDevice is running", 184 device::PowerSaveBlocker::kReasonOther, "DesktopCaptureDevice is running",
185 BrowserThread::GetTaskRunnerForThread(BrowserThread::UI), 185 BrowserThread::GetTaskRunnerForThread(BrowserThread::UI),
186 BrowserThread::GetTaskRunnerForThread(BrowserThread::FILE))); 186 BrowserThread::GetTaskRunnerForThread(BrowserThread::FILE)));
187 187
188 desktop_capturer_->Start(this); 188 desktop_capturer_->Start(this);
189 // Assume it will be always started successfully for now.
190 client_->OnStarted();
189 191
190 CaptureFrameAndScheduleNext(); 192 CaptureFrameAndScheduleNext();
191 } 193 }
192 194
193 void DesktopCaptureDevice::Core::SetNotificationWindowId( 195 void DesktopCaptureDevice::Core::SetNotificationWindowId(
194 gfx::NativeViewId window_id) { 196 gfx::NativeViewId window_id) {
195 DCHECK(task_runner_->BelongsToCurrentThread()); 197 DCHECK(task_runner_->BelongsToCurrentThread());
196 DCHECK(window_id); 198 DCHECK(window_id);
197 desktop_capturer_->SetExcludedWindow(window_id); 199 desktop_capturer_->SetExcludedWindow(window_id);
198 } 200 }
(...skipping 261 matching lines...) Expand 10 before | Expand all | Expand 10 after
460 #else 462 #else
461 base::MessageLoop::Type thread_type = base::MessageLoop::TYPE_DEFAULT; 463 base::MessageLoop::Type thread_type = base::MessageLoop::TYPE_DEFAULT;
462 #endif 464 #endif
463 465
464 thread_.StartWithOptions(base::Thread::Options(thread_type, 0)); 466 thread_.StartWithOptions(base::Thread::Options(thread_type, 0));
465 467
466 core_.reset(new Core(thread_.task_runner(), std::move(capturer), type)); 468 core_.reset(new Core(thread_.task_runner(), std::move(capturer), type));
467 } 469 }
468 470
469 } // namespace content 471 } // namespace content
OLDNEW
« no previous file with comments | « no previous file | content/browser/media/capture/desktop_capture_device_aura_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698