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

Side by Side Diff: remoting/client/chromoting_client.h

Issue 1788943002: Revert of Move NegotiatingClientAuthentication creation to ChromotingClient. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 9 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 unified diff | Download patch
« no previous file with comments | « no previous file | remoting/client/chromoting_client.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 // ChromotingClient is the controller for the Client implementation. 5 // ChromotingClient is the controller for the Client implementation.
6 6
7 #ifndef REMOTING_CLIENT_CHROMOTING_CLIENT_H_ 7 #ifndef REMOTING_CLIENT_CHROMOTING_CLIENT_H_
8 #define REMOTING_CLIENT_CHROMOTING_CLIENT_H_ 8 #define REMOTING_CLIENT_CHROMOTING_CLIENT_H_
9 9
10 #include <string> 10 #include <string>
11 11
12 #include "base/callback.h" 12 #include "base/callback.h"
13 #include "base/macros.h" 13 #include "base/macros.h"
14 #include "base/memory/scoped_ptr.h" 14 #include "base/memory/scoped_ptr.h"
15 #include "remoting/protocol/client_stub.h" 15 #include "remoting/protocol/client_stub.h"
16 #include "remoting/protocol/clipboard_stub.h" 16 #include "remoting/protocol/clipboard_stub.h"
17 #include "remoting/protocol/connection_to_host.h" 17 #include "remoting/protocol/connection_to_host.h"
18 #include "remoting/protocol/input_stub.h" 18 #include "remoting/protocol/input_stub.h"
19 #include "remoting/protocol/negotiating_client_authenticator.h"
20 #include "remoting/protocol/performance_tracker.h" 19 #include "remoting/protocol/performance_tracker.h"
21 #include "remoting/protocol/session_config.h" 20 #include "remoting/protocol/session_config.h"
22 #include "remoting/protocol/video_stub.h" 21 #include "remoting/protocol/video_stub.h"
23 #include "remoting/signaling/signal_strategy.h" 22 #include "remoting/signaling/signal_strategy.h"
24 23
25 namespace base { 24 namespace base {
26 class SingleThreadTaskRunner; 25 class SingleThreadTaskRunner;
27 } // namespace base 26 } // namespace base
28 27
29 namespace remoting { 28 namespace remoting {
(...skipping 27 matching lines...) Expand all
57 56
58 void set_protocol_config(scoped_ptr<protocol::CandidateSessionConfig> config); 57 void set_protocol_config(scoped_ptr<protocol::CandidateSessionConfig> config);
59 58
60 // Used to set fake/mock objects for tests which use the ChromotingClient. 59 // Used to set fake/mock objects for tests which use the ChromotingClient.
61 void SetConnectionToHostForTests( 60 void SetConnectionToHostForTests(
62 scoped_ptr<protocol::ConnectionToHost> connection_to_host); 61 scoped_ptr<protocol::ConnectionToHost> connection_to_host);
63 62
64 // Start the client. Must be called on the main thread. |signal_strategy| 63 // Start the client. Must be called on the main thread. |signal_strategy|
65 // must outlive the client. 64 // must outlive the client.
66 void Start(SignalStrategy* signal_strategy, 65 void Start(SignalStrategy* signal_strategy,
67 const protocol::ClientAuthenticationConfig& client_auth_config, 66 scoped_ptr<protocol::Authenticator> authenticator,
68 scoped_refptr<protocol::TransportContext> transport_context, 67 scoped_refptr<protocol::TransportContext> transport_context,
69 const std::string& host_jid, 68 const std::string& host_jid,
70 const std::string& capabilities); 69 const std::string& capabilities);
71 70
72 protocol::ConnectionToHost::State connection_state() const { 71 protocol::ConnectionToHost::State connection_state() const {
73 return connection_->state(); 72 return connection_->state();
74 } 73 }
75 74
76 protocol::ClipboardStub* clipboard_forwarder() { 75 protocol::ClipboardStub* clipboard_forwarder() {
77 return connection_->clipboard_forwarder(); 76 return connection_->clipboard_forwarder();
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
115 base::ThreadChecker thread_checker_; 114 base::ThreadChecker thread_checker_;
116 115
117 scoped_ptr<protocol::CandidateSessionConfig> protocol_config_; 116 scoped_ptr<protocol::CandidateSessionConfig> protocol_config_;
118 117
119 // The following are not owned by this class. 118 // The following are not owned by this class.
120 ClientUserInterface* user_interface_ = nullptr; 119 ClientUserInterface* user_interface_ = nullptr;
121 protocol::VideoRenderer* video_renderer_ = nullptr; 120 protocol::VideoRenderer* video_renderer_ = nullptr;
122 SignalStrategy* signal_strategy_ = nullptr; 121 SignalStrategy* signal_strategy_ = nullptr;
123 122
124 std::string host_jid_; 123 std::string host_jid_;
125 protocol::ClientAuthenticationConfig client_auth_config_; 124 scoped_ptr<protocol::Authenticator> authenticator_;
126 scoped_refptr<protocol::TransportContext> transport_context_; 125 scoped_refptr<protocol::TransportContext> transport_context_;
127 126
128 scoped_ptr<protocol::SessionManager> session_manager_; 127 scoped_ptr<protocol::SessionManager> session_manager_;
129 scoped_ptr<protocol::ConnectionToHost> connection_; 128 scoped_ptr<protocol::ConnectionToHost> connection_;
130 129
131 scoped_ptr<AudioDecodeScheduler> audio_decode_scheduler_; 130 scoped_ptr<AudioDecodeScheduler> audio_decode_scheduler_;
132 131
133 std::string local_capabilities_; 132 std::string local_capabilities_;
134 133
135 // The set of all capabilities supported by the host. 134 // The set of all capabilities supported by the host.
136 std::string host_capabilities_; 135 std::string host_capabilities_;
137 136
138 // True if |protocol::Capabilities| message has been received. 137 // True if |protocol::Capabilities| message has been received.
139 bool host_capabilities_received_ = false; 138 bool host_capabilities_received_ = false;
140 139
141 // Record the statistics of the connection. 140 // Record the statistics of the connection.
142 protocol::PerformanceTracker perf_tracker_; 141 protocol::PerformanceTracker perf_tracker_;
143 142
144 DISALLOW_COPY_AND_ASSIGN(ChromotingClient); 143 DISALLOW_COPY_AND_ASSIGN(ChromotingClient);
145 }; 144 };
146 145
147 } // namespace remoting 146 } // namespace remoting
148 147
149 #endif // REMOTING_CLIENT_CHROMOTING_CLIENT_H_ 148 #endif // REMOTING_CLIENT_CHROMOTING_CLIENT_H_
OLDNEW
« no previous file with comments | « no previous file | remoting/client/chromoting_client.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698