| 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 // TODO(ajwong): We need to come up with a better description of the | 5 // TODO(ajwong): We need to come up with a better description of the |
| 6 // responsibilities for each thread. | 6 // responsibilities for each thread. |
| 7 | 7 |
| 8 #ifndef REMOTING_CLIENT_PLUGIN_CHROMOTING_INSTANCE_H_ | 8 #ifndef REMOTING_CLIENT_PLUGIN_CHROMOTING_INSTANCE_H_ |
| 9 #define REMOTING_CLIENT_PLUGIN_CHROMOTING_INSTANCE_H_ | 9 #define REMOTING_CLIENT_PLUGIN_CHROMOTING_INSTANCE_H_ |
| 10 | 10 |
| (...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 57 | 57 |
| 58 class ChromotingInstance : public pp::InstancePrivate { | 58 class ChromotingInstance : public pp::InstancePrivate { |
| 59 public: | 59 public: |
| 60 // The mimetype for which this plugin is registered. | 60 // The mimetype for which this plugin is registered. |
| 61 static const char *kMimeType; | 61 static const char *kMimeType; |
| 62 | 62 |
| 63 explicit ChromotingInstance(PP_Instance instance); | 63 explicit ChromotingInstance(PP_Instance instance); |
| 64 virtual ~ChromotingInstance(); | 64 virtual ~ChromotingInstance(); |
| 65 | 65 |
| 66 // pp::Instance interface. | 66 // pp::Instance interface. |
| 67 virtual void DidChangeView(const pp::Rect& position, const pp::Rect& clip) | 67 virtual void DidChangeView(const pp::Rect& position, |
| 68 OVERRIDE; | 68 const pp::Rect& clip) OVERRIDE; |
| 69 virtual bool Init(uint32_t argc, const char* argn[], const char* argv[]) | 69 virtual bool Init(uint32_t argc, const char* argn[], |
| 70 OVERRIDE; | 70 const char* argv[]) OVERRIDE; |
| 71 virtual bool HandleInputEvent(const pp::InputEvent& event) OVERRIDE; | 71 virtual bool HandleInputEvent(const pp::InputEvent& event) OVERRIDE; |
| 72 | 72 |
| 73 // pp::InstancePrivate interface. | 73 // pp::InstancePrivate interface. |
| 74 virtual pp::Var GetInstanceObject() OVERRIDE; | 74 virtual pp::Var GetInstanceObject() OVERRIDE; |
| 75 | 75 |
| 76 // Convenience wrapper to get the ChromotingScriptableObject. | 76 // Convenience wrapper to get the ChromotingScriptableObject. |
| 77 ChromotingScriptableObject* GetScriptableObject(); | 77 ChromotingScriptableObject* GetScriptableObject(); |
| 78 | 78 |
| 79 // Initiates and cancels connections. | 79 // Initiates and cancels connections. |
| 80 void Connect(const ClientConfig& config); | 80 void Connect(const ClientConfig& config); |
| (...skipping 94 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 175 | 175 |
| 176 ScopedRunnableMethodFactory<ChromotingInstance> task_factory_; | 176 ScopedRunnableMethodFactory<ChromotingInstance> task_factory_; |
| 177 scoped_ptr<Task> delayed_connect_; | 177 scoped_ptr<Task> delayed_connect_; |
| 178 | 178 |
| 179 DISALLOW_COPY_AND_ASSIGN(ChromotingInstance); | 179 DISALLOW_COPY_AND_ASSIGN(ChromotingInstance); |
| 180 }; | 180 }; |
| 181 | 181 |
| 182 } // namespace remoting | 182 } // namespace remoting |
| 183 | 183 |
| 184 #endif // REMOTING_CLIENT_PLUGIN_CHROMOTING_INSTANCE_H_ | 184 #endif // REMOTING_CLIENT_PLUGIN_CHROMOTING_INSTANCE_H_ |
| OLD | NEW |