| OLD | NEW |
| 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 #ifndef REMOTING_CLIENT_CLIENT_USER_INTERFACE_H_ | 5 #ifndef REMOTING_CLIENT_CLIENT_USER_INTERFACE_H_ |
| 6 #define REMOTING_CLIENT_CLIENT_USER_INTERFACE_H_ | 6 #define REMOTING_CLIENT_CLIENT_USER_INTERFACE_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
| (...skipping 15 matching lines...) Expand all Loading... |
| 26 // | 26 // |
| 27 // TODO(sergeyu): Cleanup this interface, see crbug.com/138108 . | 27 // TODO(sergeyu): Cleanup this interface, see crbug.com/138108 . |
| 28 class ClientUserInterface { | 28 class ClientUserInterface { |
| 29 public: | 29 public: |
| 30 virtual ~ClientUserInterface() {} | 30 virtual ~ClientUserInterface() {} |
| 31 | 31 |
| 32 // Record the update the state of the connection, updating the UI as needed. | 32 // Record the update the state of the connection, updating the UI as needed. |
| 33 virtual void OnConnectionState(protocol::ConnectionToHost::State state, | 33 virtual void OnConnectionState(protocol::ConnectionToHost::State state, |
| 34 protocol::ErrorCode error) = 0; | 34 protocol::ErrorCode error) = 0; |
| 35 virtual void OnConnectionReady(bool ready) = 0; | 35 virtual void OnConnectionReady(bool ready) = 0; |
| 36 virtual void OnRouteChanged(const std::string& channel_name, |
| 37 const protocol::TransportRoute& route) = 0; |
| 36 | 38 |
| 37 // Passes the final set of capabilities negotiated between the client and host | 39 // Passes the final set of capabilities negotiated between the client and host |
| 38 // to the application. | 40 // to the application. |
| 39 virtual void SetCapabilities(const std::string& capabilities) = 0; | 41 virtual void SetCapabilities(const std::string& capabilities) = 0; |
| 40 | 42 |
| 41 // Passes a pairing response message to the client. | 43 // Passes a pairing response message to the client. |
| 42 virtual void SetPairingResponse( | 44 virtual void SetPairingResponse( |
| 43 const protocol::PairingResponse& pairing_response) = 0; | 45 const protocol::PairingResponse& pairing_response) = 0; |
| 44 | 46 |
| 45 // Deliver an extension message from the host to the client. | 47 // Deliver an extension message from the host to the client. |
| 46 virtual void DeliverHostMessage( | 48 virtual void DeliverHostMessage( |
| 47 const protocol::ExtensionMessage& message) = 0; | 49 const protocol::ExtensionMessage& message) = 0; |
| 48 | 50 |
| 49 // Get the view's ClipboardStub implementation. | 51 // Get the view's ClipboardStub implementation. |
| 50 virtual protocol::ClipboardStub* GetClipboardStub() = 0; | 52 virtual protocol::ClipboardStub* GetClipboardStub() = 0; |
| 51 | 53 |
| 52 // Get the view's CursorShapeStub implementation. | 54 // Get the view's CursorShapeStub implementation. |
| 53 virtual protocol::CursorShapeStub* GetCursorShapeStub() = 0; | 55 virtual protocol::CursorShapeStub* GetCursorShapeStub() = 0; |
| 54 | 56 |
| 55 // Get the view's TokenFetcher implementation. | 57 // Get the view's TokenFetcher implementation. |
| 56 // The TokenFetcher implementation may require interactive authentication. | 58 // The TokenFetcher implementation may require interactive authentication. |
| 57 virtual scoped_ptr<protocol::ThirdPartyClientAuthenticator::TokenFetcher> | 59 virtual scoped_ptr<protocol::ThirdPartyClientAuthenticator::TokenFetcher> |
| 58 GetTokenFetcher(const std::string& host_public_key) = 0; | 60 GetTokenFetcher(const std::string& host_public_key) = 0; |
| 59 }; | 61 }; |
| 60 | 62 |
| 61 } // namespace remoting | 63 } // namespace remoting |
| 62 | 64 |
| 63 #endif // REMOTING_CLIENT_CLIENT_USER_INTERFACE_H_ | 65 #endif // REMOTING_CLIENT_CLIENT_USER_INTERFACE_H_ |
| OLD | NEW |