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

Unified Diff: trunk/src/remoting/host/desktop_session_proxy.cc

Issue 151163002: Revert 248045 "Use webrtc::MouseCursorMonitor for cursor shapes" (Closed) Base URL: svn://svn.chromium.org/chrome/
Patch Set: Created 6 years, 11 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
« no previous file with comments | « trunk/src/remoting/host/desktop_session_proxy.h ('k') | trunk/src/remoting/host/host_mock_objects.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: trunk/src/remoting/host/desktop_session_proxy.cc
===================================================================
--- trunk/src/remoting/host/desktop_session_proxy.cc (revision 248137)
+++ trunk/src/remoting/host/desktop_session_proxy.cc (working copy)
@@ -19,7 +19,6 @@
#include "remoting/host/desktop_session_connector.h"
#include "remoting/host/ipc_audio_capturer.h"
#include "remoting/host/ipc_input_injector.h"
-#include "remoting/host/ipc_mouse_cursor_monitor.h"
#include "remoting/host/ipc_screen_controls.h"
#include "remoting/host/ipc_video_frame_capturer.h"
#include "remoting/proto/audio.pb.h"
@@ -27,7 +26,6 @@
#include "remoting/proto/event.pb.h"
#include "third_party/webrtc/modules/desktop_capture/desktop_frame.h"
#include "third_party/webrtc/modules/desktop_capture/desktop_geometry.h"
-#include "third_party/webrtc/modules/desktop_capture/mouse_cursor.h"
#include "third_party/webrtc/modules/desktop_capture/shared_memory.h"
#if defined(OS_WIN)
@@ -146,12 +144,6 @@
return scoped_ptr<webrtc::ScreenCapturer>(new IpcVideoFrameCapturer(this));
}
-scoped_ptr<webrtc::MouseCursorMonitor>
- DesktopSessionProxy::CreateMouseCursorMonitor() {
- return scoped_ptr<webrtc::MouseCursorMonitor>(
- new IpcMouseCursorMonitor(this));
-}
-
std::string DesktopSessionProxy::GetCapabilities() const {
std::string result = kRateLimitResizeRequests;
// Ask the client to send its resolution unconditionally.
@@ -191,8 +183,8 @@
OnAudioPacket)
IPC_MESSAGE_HANDLER(ChromotingDesktopNetworkMsg_CaptureCompleted,
OnCaptureCompleted)
- IPC_MESSAGE_HANDLER(ChromotingDesktopNetworkMsg_MouseCursor,
- OnMouseCursor)
+ IPC_MESSAGE_HANDLER(ChromotingDesktopNetworkMsg_CursorShapeChanged,
+ OnCursorShapeChanged)
IPC_MESSAGE_HANDLER(ChromotingDesktopNetworkMsg_CreateSharedBuffer,
OnCreateSharedBuffer)
IPC_MESSAGE_HANDLER(ChromotingDesktopNetworkMsg_ReleaseSharedBuffer,
@@ -326,13 +318,6 @@
video_capturer_ = video_capturer;
}
-void DesktopSessionProxy::SetMouseCursorMonitor(
- const base::WeakPtr<IpcMouseCursorMonitor>& mouse_cursor_monitor) {
- DCHECK(video_capture_task_runner_->BelongsToCurrentThread());
-
- mouse_cursor_monitor_ = mouse_cursor_monitor;
-}
-
void DesktopSessionProxy::DisconnectSession() {
DCHECK(caller_task_runner_->BelongsToCurrentThread());
@@ -506,12 +491,11 @@
PostCaptureCompleted(frame.Pass());
}
-void DesktopSessionProxy::OnMouseCursor(
- const webrtc::MouseCursor& mouse_cursor) {
+void DesktopSessionProxy::OnCursorShapeChanged(
+ const webrtc::MouseCursorShape& cursor_shape) {
DCHECK(caller_task_runner_->BelongsToCurrentThread());
- scoped_ptr<webrtc::MouseCursor> cursor(
- webrtc::MouseCursor::CopyOf(mouse_cursor));
- PostMouseCursor(cursor.Pass());
+ PostCursorShape(scoped_ptr<webrtc::MouseCursorShape>(
+ new webrtc::MouseCursorShape(cursor_shape)));
}
void DesktopSessionProxy::OnInjectClipboardEvent(
@@ -539,14 +523,14 @@
base::Passed(&frame)));
}
-void DesktopSessionProxy::PostMouseCursor(
- scoped_ptr<webrtc::MouseCursor> mouse_cursor) {
+void DesktopSessionProxy::PostCursorShape(
+ scoped_ptr<webrtc::MouseCursorShape> cursor_shape) {
DCHECK(caller_task_runner_->BelongsToCurrentThread());
video_capture_task_runner_->PostTask(
FROM_HERE,
- base::Bind(&IpcMouseCursorMonitor::OnMouseCursor, mouse_cursor_monitor_,
- base::Passed(&mouse_cursor)));
+ base::Bind(&IpcVideoFrameCapturer::OnCursorShapeChanged, video_capturer_,
+ base::Passed(&cursor_shape)));
}
void DesktopSessionProxy::SendToDesktop(IPC::Message* message) {
« no previous file with comments | « trunk/src/remoting/host/desktop_session_proxy.h ('k') | trunk/src/remoting/host/host_mock_objects.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698