| OLD | NEW |
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 #ifndef REMOTING_PROTOCOL_CONNECTION_TO_CLIENT_H_ | 5 #ifndef REMOTING_PROTOCOL_CONNECTION_TO_CLIENT_H_ |
| 6 #define REMOTING_PROTOCOL_CONNECTION_TO_CLIENT_H_ | 6 #define REMOTING_PROTOCOL_CONNECTION_TO_CLIENT_H_ |
| 7 | 7 |
| 8 #include <deque> | 8 #include <deque> |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| 11 #include "base/message_loop.h" | 11 #include "base/message_loop.h" |
| (...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 68 | 68 |
| 69 // Send encoded update stream data to the viewer. | 69 // Send encoded update stream data to the viewer. |
| 70 virtual VideoStub* video_stub(); | 70 virtual VideoStub* video_stub(); |
| 71 | 71 |
| 72 // Return pointer to ClientStub. | 72 // Return pointer to ClientStub. |
| 73 virtual ClientStub* client_stub(); | 73 virtual ClientStub* client_stub(); |
| 74 | 74 |
| 75 // Called when the host accepts the client authentication. | 75 // Called when the host accepts the client authentication. |
| 76 void OnClientAuthenticated(); | 76 void OnClientAuthenticated(); |
| 77 | 77 |
| 78 // Whether the client has been authenticated. |
| 79 bool client_authenticated(); |
| 80 |
| 78 private: | 81 private: |
| 79 // Callback for protocol Session. | 82 // Callback for protocol Session. |
| 80 void OnSessionStateChange(Session::State state); | 83 void OnSessionStateChange(Session::State state); |
| 81 | 84 |
| 82 // Process a libjingle state change event on the |loop_|. | 85 // Process a libjingle state change event on the |loop_|. |
| 83 void StateChangeTask(Session::State state); | 86 void StateChangeTask(Session::State state); |
| 84 | 87 |
| 85 void OnClosed(); | 88 void OnClosed(); |
| 86 | 89 |
| 87 // Initially false, this is set to true once the client has authenticated | 90 // Initially false, this is set to true once the client has authenticated |
| (...skipping 24 matching lines...) Expand all Loading... |
| 112 // Dispatcher for submitting messages to stubs. | 115 // Dispatcher for submitting messages to stubs. |
| 113 scoped_ptr<HostMessageDispatcher> dispatcher_; | 116 scoped_ptr<HostMessageDispatcher> dispatcher_; |
| 114 | 117 |
| 115 DISALLOW_COPY_AND_ASSIGN(ConnectionToClient); | 118 DISALLOW_COPY_AND_ASSIGN(ConnectionToClient); |
| 116 }; | 119 }; |
| 117 | 120 |
| 118 } // namespace protocol | 121 } // namespace protocol |
| 119 } // namespace remoting | 122 } // namespace remoting |
| 120 | 123 |
| 121 #endif // REMOTING_PROTOCOL_CONNECTION_TO_CLIENT_H_ | 124 #endif // REMOTING_PROTOCOL_CONNECTION_TO_CLIENT_H_ |
| OLD | NEW |