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

Unified Diff: remoting/protocol/webrtc_transport.h

Issue 1662673002: Add MessageChanneFactory interface and use it in ChannelDispatcherBase. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@framing
Patch Set: Created 4 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 | « remoting/protocol/webrtc_connection_to_host.cc ('k') | remoting/protocol/webrtc_transport.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: remoting/protocol/webrtc_transport.h
diff --git a/remoting/protocol/webrtc_transport.h b/remoting/protocol/webrtc_transport.h
index 8a7f43bdadbdd26d34ff50ce7b28f4ba16037cfc..b19d84a7d7dd49c6ae9f7a4205bf2bc119f50c2b 100644
--- a/remoting/protocol/webrtc_transport.h
+++ b/remoting/protocol/webrtc_transport.h
@@ -26,6 +26,7 @@ namespace remoting {
namespace protocol {
class TransportContext;
+class MessageChannelFactory;
class WebrtcTransport : public Transport,
public webrtc::PeerConnectionObserver {
@@ -67,11 +68,11 @@ class WebrtcTransport : public Transport,
// Factories for outgoing and incoming data channels. Must be used only after
// the transport is connected.
- StreamChannelFactory* outgoing_channel_factory() {
- return &outgoing_data_stream_adapter_;
+ MessageChannelFactory* outgoing_channel_factory() {
+ return outgoing_channel_factory_.get();
}
- StreamChannelFactory* incoming_channel_factory() {
- return &incoming_data_stream_adapter_;
+ MessageChannelFactory* incoming_channel_factory() {
+ return incoming_channel_factory_.get();
}
// Transport interface.
@@ -134,6 +135,11 @@ class WebrtcTransport : public Transport,
WebrtcDataStreamAdapter outgoing_data_stream_adapter_;
WebrtcDataStreamAdapter incoming_data_stream_adapter_;
+ // TODO(sergeyu): Remove these and implement MessageChannelFactory in
+ // WebrtcDataStreamAdapter.
+ scoped_ptr<MessageChannelFactory> outgoing_channel_factory_;
+ scoped_ptr<MessageChannelFactory> incoming_channel_factory_;
+
base::WeakPtrFactory<WebrtcTransport> weak_factory_;
DISALLOW_COPY_AND_ASSIGN(WebrtcTransport);
« no previous file with comments | « remoting/protocol/webrtc_connection_to_host.cc ('k') | remoting/protocol/webrtc_transport.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698