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

Unified Diff: remoting/protocol/webrtc_connection_to_client.cc

Issue 2413553003: Add InputEventTimestampSource interface. (Closed)
Patch Set: Created 4 years, 2 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/protocol/webrtc_connection_to_client.cc
diff --git a/remoting/protocol/webrtc_connection_to_client.cc b/remoting/protocol/webrtc_connection_to_client.cc
index a1df3511fd36107269be16ba5f745283b5ffaf3d..415679501483ce481f2bd222c01f62268c2c06c4 100644
--- a/remoting/protocol/webrtc_connection_to_client.cc
+++ b/remoting/protocol/webrtc_connection_to_client.cc
@@ -83,6 +83,7 @@ std::unique_ptr<VideoStream> WebrtcConnectionToClient::StartVideoStream(
std::unique_ptr<WebrtcVideoStream> stream(new WebrtcVideoStream());
stream->Start(std::move(desktop_capturer), transport_.get(),
video_encode_task_runner_);
+ stream->SetEventTimestampSource(event_dispatcher_->GetEventTimestampSource());
return std::move(stream);
}
@@ -181,9 +182,6 @@ void WebrtcConnectionToClient::OnWebrtcTransportIncomingDataChannel(
DCHECK(thread_checker_.CalledOnValidThread());
if (name == event_dispatcher_->channel_name() &&
!event_dispatcher_->is_connected()) {
- event_dispatcher_->set_on_input_event_callback(
- base::Bind(&WebrtcConnectionToClient::OnInputEventReceived,
- base::Unretained(this)));
event_dispatcher_->Init(std::move(pipe), this);
}
}
@@ -218,10 +216,5 @@ void WebrtcConnectionToClient::OnChannelClosed(
Disconnect(INCOMPATIBLE_PROTOCOL);
}
-void WebrtcConnectionToClient::OnInputEventReceived(int64_t timestamp) {
- DCHECK(thread_checker_.CalledOnValidThread());
- event_handler_->OnInputEventReceived(timestamp);
-}
-
} // namespace protocol
} // namespace remoting

Powered by Google App Engine
This is Rietveld 408576698