1 /* 2 * Copyright (c) 2013 The WebRTC project authors. All Rights Reserved. 3 * 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 6 * tree. An additional intellectual property rights grant can be found 7 * in the file PATENTS. All contributing project authors may 8 * be found in the AUTHORS file in the root of the source tree. 9 */ 10 11 #include "modules/desktop_capture/desktop_capture_options.h" 12 #if defined(WEBRTC_MAC) && !defined(WEBRTC_IOS) 13 #include "modules/desktop_capture/mac/full_screen_mac_application_handler.h" 14 #elif defined(WEBRTC_WIN) 15 #include "modules/desktop_capture/win/full_screen_win_application_handler.h" 16 #endif 17 18 namespace webrtc { 19 DesktopCaptureOptions()20DesktopCaptureOptions::DesktopCaptureOptions() {} 21 DesktopCaptureOptions::DesktopCaptureOptions( 22 const DesktopCaptureOptions& options) = default; 23 DesktopCaptureOptions::DesktopCaptureOptions(DesktopCaptureOptions&& options) = 24 default; ~DesktopCaptureOptions()25DesktopCaptureOptions::~DesktopCaptureOptions() {} 26 27 DesktopCaptureOptions& DesktopCaptureOptions::operator=( 28 const DesktopCaptureOptions& options) = default; 29 DesktopCaptureOptions& DesktopCaptureOptions::operator=( 30 DesktopCaptureOptions&& options) = default; 31 32 // static CreateDefault()33DesktopCaptureOptions DesktopCaptureOptions::CreateDefault() { 34 DesktopCaptureOptions result; 35 #if defined(WEBRTC_USE_X11) 36 result.set_x_display(SharedXDisplay::CreateDefault()); 37 #endif 38 #if defined(WEBRTC_MAC) && !defined(WEBRTC_IOS) 39 result.set_configuration_monitor(new DesktopConfigurationMonitor()); 40 result.set_full_screen_window_detector( 41 new FullScreenWindowDetector(CreateFullScreenMacApplicationHandler)); 42 #elif defined(WEBRTC_WIN) 43 result.set_full_screen_window_detector( 44 new FullScreenWindowDetector(CreateFullScreenWinApplicationHandler)); 45 #endif 46 return result; 47 } 48 49 } // namespace webrtc 50