OLD | NEW |
1 // -*- c++ -*- | 1 // -*- c++ -*- |
2 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 2 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
3 // Use of this source code is governed by a BSD-style license that can be | 3 // Use of this source code is governed by a BSD-style license that can be |
4 // found in the LICENSE file. | 4 // found in the LICENSE file. |
5 | 5 |
6 // The portable representation of an instance and root scriptable object. | 6 // The portable representation of an instance and root scriptable object. |
7 // The PPAPI version of the plugin instantiates a subclass of this class. | 7 // The PPAPI version of the plugin instantiates a subclass of this class. |
8 | 8 |
9 #ifndef NATIVE_CLIENT_SRC_TRUSTED_PLUGIN_PLUGIN_H_ | 9 #ifndef NATIVE_CLIENT_SRC_TRUSTED_PLUGIN_PLUGIN_H_ |
10 #define NATIVE_CLIENT_SRC_TRUSTED_PLUGIN_PLUGIN_H_ | 10 #define NATIVE_CLIENT_SRC_TRUSTED_PLUGIN_PLUGIN_H_ |
(...skipping 299 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
310 const pp::URLUtil_Dev* url_util() const { return url_util_; } | 310 const pp::URLUtil_Dev* url_util() const { return url_util_; } |
311 | 311 |
312 // Extracts the exit status from the (main) service runtime. | 312 // Extracts the exit status from the (main) service runtime. |
313 int exit_status() const { | 313 int exit_status() const { |
314 if (NULL == main_service_runtime()) { | 314 if (NULL == main_service_runtime()) { |
315 return -1; | 315 return -1; |
316 } | 316 } |
317 return main_service_runtime()->exit_status(); | 317 return main_service_runtime()->exit_status(); |
318 } | 318 } |
319 | 319 |
| 320 const PPB_NaCl_Private* nacl_interface() { return nacl_interface_; } |
| 321 |
320 private: | 322 private: |
321 NACL_DISALLOW_COPY_AND_ASSIGN(Plugin); | 323 NACL_DISALLOW_COPY_AND_ASSIGN(Plugin); |
322 // Prevent construction and destruction from outside the class: | 324 // Prevent construction and destruction from outside the class: |
323 // must use factory New() method instead. | 325 // must use factory New() method instead. |
324 explicit Plugin(PP_Instance instance); | 326 explicit Plugin(PP_Instance instance); |
325 // The browser will invoke the destructor via the pp::Instance | 327 // The browser will invoke the destructor via the pp::Instance |
326 // pointer to this object, not from base's Delete(). | 328 // pointer to this object, not from base's Delete(). |
327 ~Plugin(); | 329 ~Plugin(); |
328 | 330 |
329 bool Init(int argc, char* argn[], char* argv[]); | 331 bool Init(int argc, char* argn[], char* argv[]); |
(...skipping 197 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
527 | 529 |
528 // Whether we are using IPC-based PPAPI proxy. | 530 // Whether we are using IPC-based PPAPI proxy. |
529 bool using_ipc_proxy_; | 531 bool using_ipc_proxy_; |
530 | 532 |
531 const PPB_NaCl_Private* nacl_interface_; | 533 const PPB_NaCl_Private* nacl_interface_; |
532 }; | 534 }; |
533 | 535 |
534 } // namespace plugin | 536 } // namespace plugin |
535 | 537 |
536 #endif // NATIVE_CLIENT_SRC_TRUSTED_PLUGIN_PLUGIN_H_ | 538 #endif // NATIVE_CLIENT_SRC_TRUSTED_PLUGIN_PLUGIN_H_ |
OLD | NEW |