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

Unified Diff: remoting/host/single_window_input_injector.h

Issue 422503004: Adding ability to stream windows and inject events to them (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Updated if directive Created 6 years, 4 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 side-by-side diff with in-line comments
Download patch
Index: remoting/host/single_window_input_injector.h
diff --git a/remoting/host/single_window_input_injector.h b/remoting/host/single_window_input_injector.h
new file mode 100644
index 0000000000000000000000000000000000000000..3deb743548248ddf3f4184e3efeed663f4015e95
--- /dev/null
+++ b/remoting/host/single_window_input_injector.h
@@ -0,0 +1,30 @@
+// Copyright 2014 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef REMOTING_HOST_SINGLE_WINDOW_INPUT_INJECTOR_H_
+#define REMOTING_HOST_SINGLE_WINDOW_INPUT_INJECTOR_H_
+
+#include "base/memory/scoped_ptr.h"
+#include "remoting/host/input_injector.h"
+#include "third_party/webrtc/modules/desktop_capture/desktop_capture_types.h"
+
+namespace remoting {
+
+// This class is used to wrap an InputInjector. All this class does
+// is forward messages to the wrapped InputInjector. When a MouseEvent
+// comes in, SingleWindowInputInjector adjusts the MouseEvent's
+// coordinates so that they are in respect to the window instead of
+// the desktop. Clipboard, Text, and Key events are still global.
+class SingleWindowInputInjector : public InputInjector {
+ public:
+ // This Create method needs to be passed a full desktop
+ // InputInjector.
+ static scoped_ptr<InputInjector> Create(
+ webrtc::WindowId window_id,
+ scoped_ptr<InputInjector> input_injector);
+};
+
+} // namespace remoting
+
+#endif // REMOTING_HOST_SINGLE_WINDOW_INPUT_INJECTOR_H_

Powered by Google App Engine
This is Rietveld 408576698