| OLD | NEW |
| 1 // Copyright (c) 2011 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_HOST_PLUGIN_HOST_SCRIPT_OBJECT_H_ | 5 #ifndef REMOTING_HOST_PLUGIN_HOST_SCRIPT_OBJECT_H_ |
| 6 #define REMOTING_HOST_PLUGIN_HOST_SCRIPT_OBJECT_H_ | 6 #define REMOTING_HOST_PLUGIN_HOST_SCRIPT_OBJECT_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| (...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 111 void SetState(State state); | 111 void SetState(State state); |
| 112 | 112 |
| 113 // Notifies OnStateChanged handler of a state change. | 113 // Notifies OnStateChanged handler of a state change. |
| 114 void NotifyStateChanged(State state); | 114 void NotifyStateChanged(State state); |
| 115 | 115 |
| 116 // Call LogDebugInfo handler if there is one. | 116 // Call LogDebugInfo handler if there is one. |
| 117 // This must be called on the correct thread. | 117 // This must be called on the correct thread. |
| 118 void LogDebugInfo(const std::string& message); | 118 void LogDebugInfo(const std::string& message); |
| 119 | 119 |
| 120 // Callbacks invoked during session setup. | 120 // Callbacks invoked during session setup. |
| 121 void OnReceivedSupportID(remoting::SupportAccessVerifier* access_verifier, | 121 void OnReceivedSupportID(bool success, |
| 122 bool success, | |
| 123 const std::string& support_id, | 122 const std::string& support_id, |
| 124 const base::TimeDelta& lifetime); | 123 const base::TimeDelta& lifetime); |
| 125 void NotifyAccessCode(bool success); | 124 void NotifyAccessCode(bool success); |
| 126 | 125 |
| 127 // Helper functions that run on main thread. Can be called on any | 126 // Helper functions that run on main thread. Can be called on any |
| 128 // other thread. | 127 // other thread. |
| 129 void ReadPolicyAndConnect(const std::string& uid, | 128 void ReadPolicyAndConnect(const std::string& uid, |
| 130 const std::string& auth_token, | 129 const std::string& auth_token, |
| 131 const std::string& auth_service); | 130 const std::string& auth_service); |
| 132 void FinishConnect(const std::string& uid, | 131 void FinishConnect(const std::string& uid, |
| (...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 214 // it can be executed after at least one successful policy read. This | 213 // it can be executed after at least one successful policy read. This |
| 215 // variable contains the thunk if it is necessary. | 214 // variable contains the thunk if it is necessary. |
| 216 base::Closure pending_connect_; | 215 base::Closure pending_connect_; |
| 217 }; | 216 }; |
| 218 | 217 |
| 219 } // namespace remoting | 218 } // namespace remoting |
| 220 | 219 |
| 221 DISABLE_RUNNABLE_METHOD_REFCOUNT(remoting::HostNPScriptObject); | 220 DISABLE_RUNNABLE_METHOD_REFCOUNT(remoting::HostNPScriptObject); |
| 222 | 221 |
| 223 #endif // REMOTING_HOST_PLUGIN_HOST_SCRIPT_OBJECT_H_ | 222 #endif // REMOTING_HOST_PLUGIN_HOST_SCRIPT_OBJECT_H_ |
| OLD | NEW |