 Chromium Code Reviews
 Chromium Code Reviews Issue 9921034:
  [Chromoting] Add plumbing to carry clipboard events from the host to the client.  (Closed) 
  Base URL: svn://svn.chromium.org/chrome/trunk/src
    
  
    Issue 9921034:
  [Chromoting] Add plumbing to carry clipboard events from the host to the client.  (Closed) 
  Base URL: svn://svn.chromium.org/chrome/trunk/src| Index: remoting/protocol/client_control_dispatcher.cc | 
| diff --git a/remoting/protocol/client_control_dispatcher.cc b/remoting/protocol/client_control_dispatcher.cc | 
| index b1aefc2f3da0c6c2bcfaa249afedae16dae9c2d8..b6e8250d761319adfb89d3e4b6ba864c5f4242fe 100644 | 
| --- a/remoting/protocol/client_control_dispatcher.cc | 
| +++ b/remoting/protocol/client_control_dispatcher.cc | 
| @@ -21,6 +21,7 @@ namespace protocol { | 
| ClientControlDispatcher::ClientControlDispatcher() | 
| : ChannelDispatcherBase(kControlChannelName), | 
| client_stub_(NULL), | 
| + clipboard_stub_(NULL), | 
| writer_(new BufferedSocketWriter(base::MessageLoopProxy::current())) { | 
| } | 
| @@ -45,8 +46,14 @@ void ClientControlDispatcher::InjectClipboardEvent( | 
| void ClientControlDispatcher::OnMessageReceived( | 
| scoped_ptr<ControlMessage> message, const base::Closure& done_task) { | 
| DCHECK(client_stub_); | 
| + DCHECK(clipboard_stub_); | 
| 
Wez
2012/03/30 22:20:15
not for this CL: It feels like these checks belong
 
simonmorris
2012/03/30 22:36:07
Could be, though the stubs are used here.
 
Wez
2012/03/31 00:38:46
True.  Checking in OnMessageReceived() risks us mi
 | 
| base::ScopedClosureRunner done_runner(done_task); | 
| - LOG(WARNING) << "Unknown control message received."; | 
| + | 
| + if (message->has_clipboard_event()) { | 
| + clipboard_stub_->InjectClipboardEvent(message->clipboard_event()); | 
| + } else { | 
| + LOG(WARNING) << "Unknown control message received."; | 
| + } | 
| } | 
| } // namespace protocol |