Index: remoting/host/me2me_window_desktop_environment.h |
diff --git a/remoting/host/me2me_window_desktop_environment.h b/remoting/host/me2me_window_desktop_environment.h |
new file mode 100644 |
index 0000000000000000000000000000000000000000..83842d4eae2a117bece910ee536d1ecdafacef3c |
--- /dev/null |
+++ b/remoting/host/me2me_window_desktop_environment.h |
@@ -0,0 +1,65 @@ |
+// Copyright (c) 2012 The Chromium Authors. All rights reserved. |
Lambros
2014/07/30 00:14:49
I'm not sure if we need this new class? Maybe it's
ronakvora do not use
2014/07/30 20:55:36
See my other comment in remoting_me2me_host.cc :)!
|
+// Use of this source code is governed by a BSD-style license that can be |
+// found in the LICENSE file. |
+ |
+#ifndef REMOTING_HOST_WINDOW_DESKTOP_ENVIRONMENT_H_ |
+#define REMOTING_HOST_WINDOW_DESKTOP_ENVIRONMENT_H_ |
+ |
+#include "remoting/host/basic_desktop_environment.h" |
+#include "remoting/host/input_injector.h" |
Lambros
2014/07/30 00:14:49
nit: Don't need full definition of InputInjector c
ronakvora do not use
2014/07/30 20:55:36
Done.
|
+#include "third_party/webrtc/modules/desktop_capture/desktop_capture_types.h" |
+ |
+namespace remoting { |
+ |
+// Enables capturing and streaming of windows. |
+class Me2MeWindowDesktopEnvironment : public BasicDesktopEnvironment { |
+ public: |
+ virtual ~Me2MeWindowDesktopEnvironment(); |
+ |
+ // DesktopEnvironment interface. |
+ virtual scoped_ptr<webrtc::ScreenCapturer> CreateVideoCapturer() OVERRIDE; |
+ virtual scoped_ptr<InputInjector> CreateInputInjector() OVERRIDE; |
+ |
+ protected: |
+ friend class Me2MeWindowDesktopEnvironmentFactory; |
+ Me2MeWindowDesktopEnvironment( |
+ scoped_refptr<base::SingleThreadTaskRunner> caller_task_runner, |
+ scoped_refptr<base::SingleThreadTaskRunner> input_task_runner, |
+ scoped_refptr<base::SingleThreadTaskRunner> ui_task_runner); |
+ |
+ void SetWindowId(webrtc::WindowId windowIdEnvironment); |
+ |
+ void SetEnableWindowCapture(bool enable_window_capture); |
+ |
+ private: |
+ webrtc::WindowId windowIdEnvironment_; |
+ bool enable_window_capture_environment_; |
+ |
+ DISALLOW_COPY_AND_ASSIGN(Me2MeWindowDesktopEnvironment); |
+}; |
+ |
+// Used to create |Me2MeWindowDesktopEnvironment| instances. |
+class Me2MeWindowDesktopEnvironmentFactory : public BasicDesktopEnvironmentFactory { |
Lambros
2014/07/30 00:14:49
This breaks 80-char limit. Put ": public BasicD...
ronakvora do not use
2014/07/30 20:55:36
Done.
|
+ public: |
+ Me2MeWindowDesktopEnvironmentFactory( |
+ scoped_refptr<base::SingleThreadTaskRunner> caller_task_runner, |
+ scoped_refptr<base::SingleThreadTaskRunner> input_task_runner, |
+ scoped_refptr<base::SingleThreadTaskRunner> ui_task_runner, |
+ webrtc::WindowId windowId, |
+ bool enable_window_capture); |
+ virtual ~Me2MeWindowDesktopEnvironmentFactory(); |
+ |
+ // DesktopEnvironmentFactory interface. |
+ virtual scoped_ptr<DesktopEnvironment> Create( |
+ base::WeakPtr<ClientSessionControl> client_session_control) OVERRIDE; |
+ |
+ private: |
+ webrtc::WindowId windowIdEnvironmentFactory_; |
+ bool enable_window_capture_environment_factory_; |
+ |
+ DISALLOW_COPY_AND_ASSIGN(Me2MeWindowDesktopEnvironmentFactory); |
+}; |
+ |
+} // namespace remoting |
+ |
+#endif // REMOTING_HOST_WINDOW_DESKTOP_ENVIRONMENT_H_ |