| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (c) 2014 The WebRTC project authors. All Rights Reserved. | 2 * Copyright (c) 2014 The WebRTC project authors. All Rights Reserved. |
| 3 * | 3 * |
| 4 * Use of this source code is governed by a BSD-style license | 4 * Use of this source code is governed by a BSD-style license |
| 5 * that can be found in the LICENSE file in the root of the source | 5 * that can be found in the LICENSE file in the root of the source |
| 6 * tree. An additional intellectual property rights grant can be found | 6 * tree. An additional intellectual property rights grant can be found |
| 7 * in the file PATENTS. All contributing project authors may | 7 * in the file PATENTS. All contributing project authors may |
| 8 * be found in the AUTHORS file in the root of the source tree. | 8 * be found in the AUTHORS file in the root of the source tree. |
| 9 */ | 9 */ |
| 10 | 10 |
| (...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 75 | 75 |
| 76 void ScreenCapturerWinMagnifier::Start(Callback* callback) { | 76 void ScreenCapturerWinMagnifier::Start(Callback* callback) { |
| 77 assert(!callback_); | 77 assert(!callback_); |
| 78 assert(callback); | 78 assert(callback); |
| 79 callback_ = callback; | 79 callback_ = callback; |
| 80 | 80 |
| 81 InitializeMagnifier(); | 81 InitializeMagnifier(); |
| 82 } | 82 } |
| 83 | 83 |
| 84 void ScreenCapturerWinMagnifier::SetSharedMemoryFactory( | 84 void ScreenCapturerWinMagnifier::SetSharedMemoryFactory( |
| 85 std::unique_ptr<SharedMemoryFactory> shared_memory_factory) { | 85 rtc::scoped_ptr<SharedMemoryFactory> shared_memory_factory) { |
| 86 shared_memory_factory_ = std::move(shared_memory_factory); | 86 shared_memory_factory_ = std::move(shared_memory_factory); |
| 87 } | 87 } |
| 88 | 88 |
| 89 void ScreenCapturerWinMagnifier::Capture(const DesktopRegion& region) { | 89 void ScreenCapturerWinMagnifier::Capture(const DesktopRegion& region) { |
| 90 TickTime capture_start_time = TickTime::Now(); | 90 TickTime capture_start_time = TickTime::Now(); |
| 91 | 91 |
| 92 queue_.MoveToNextFrame(); | 92 queue_.MoveToNextFrame(); |
| 93 | 93 |
| 94 // Request that the system not power-down the system, or the display hardware. | 94 // Request that the system not power-down the system, or the display hardware. |
| 95 if (!SetThreadExecutionState(ES_DISPLAY_REQUIRED | ES_SYSTEM_REQUIRED)) { | 95 if (!SetThreadExecutionState(ES_DISPLAY_REQUIRED | ES_SYSTEM_REQUIRED)) { |
| (...skipping 344 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 440 assert(fallback_capturer_); | 440 assert(fallback_capturer_); |
| 441 if (!fallback_capturer_started_) { | 441 if (!fallback_capturer_started_) { |
| 442 fallback_capturer_started_ = true; | 442 fallback_capturer_started_ = true; |
| 443 | 443 |
| 444 fallback_capturer_->Start(callback_); | 444 fallback_capturer_->Start(callback_); |
| 445 fallback_capturer_->SelectScreen(current_screen_id_); | 445 fallback_capturer_->SelectScreen(current_screen_id_); |
| 446 } | 446 } |
| 447 } | 447 } |
| 448 | 448 |
| 449 } // namespace webrtc | 449 } // namespace webrtc |
| OLD | NEW |