| OLD | NEW |
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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 #include "remoting/client/plugin/chromoting_instance.h" | 5 #include "remoting/client/plugin/chromoting_instance.h" |
| 6 | 6 |
| 7 #include <string> | 7 #include <string> |
| 8 #include <vector> | 8 #include <vector> |
| 9 | 9 |
| 10 #include "base/message_loop.h" | 10 #include "base/message_loop.h" |
| (...skipping 165 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 176 LOG(ERROR) << "Unable to get ScriptableObject for Chromoting plugin."; | 176 LOG(ERROR) << "Unable to get ScriptableObject for Chromoting plugin."; |
| 177 return NULL; | 177 return NULL; |
| 178 } | 178 } |
| 179 | 179 |
| 180 pp::Var ChromotingInstance::GetInstanceObject() { | 180 pp::Var ChromotingInstance::GetInstanceObject() { |
| 181 if (instance_object_.is_undefined()) { | 181 if (instance_object_.is_undefined()) { |
| 182 ChromotingScriptableObject* object = new ChromotingScriptableObject(this); | 182 ChromotingScriptableObject* object = new ChromotingScriptableObject(this); |
| 183 object->Init(); | 183 object->Init(); |
| 184 | 184 |
| 185 // The pp::Var takes ownership of object here. | 185 // The pp::Var takes ownership of object here. |
| 186 instance_object_ = pp::Var(object); | 186 instance_object_ = pp::Var(this, object); |
| 187 } | 187 } |
| 188 | 188 |
| 189 return instance_object_; | 189 return instance_object_; |
| 190 } | 190 } |
| 191 | 191 |
| 192 } // namespace remoting | 192 } // namespace remoting |
| OLD | NEW |