Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(28)

Side by Side Diff: ppapi/native_client/src/trusted/plugin/plugin.h

Issue 868273002: NaCl: Fix Chromium style warnings in src/trusted/plugin/ (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Created 5 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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 45 matching lines...) Expand 10 before | Expand all | Expand 10 after
56 56
57 class Plugin : public pp::Instance { 57 class Plugin : public pp::Instance {
58 public: 58 public:
59 explicit Plugin(PP_Instance instance); 59 explicit Plugin(PP_Instance instance);
60 60
61 // ----- Methods inherited from pp::Instance: 61 // ----- Methods inherited from pp::Instance:
62 62
63 // Initializes this plugin with <embed/object ...> tag attribute count |argc|, 63 // Initializes this plugin with <embed/object ...> tag attribute count |argc|,
64 // names |argn| and values |argn|. Returns false on failure. 64 // names |argn| and values |argn|. Returns false on failure.
65 // Gets called by the browser right after New(). 65 // Gets called by the browser right after New().
66 virtual bool Init(uint32_t argc, const char* argn[], const char* argv[]); 66 bool Init(uint32_t argc, const char* argn[], const char* argv[]) override;
67 67
68 // Handles document load, when the plugin is a MIME type handler. 68 // Handles document load, when the plugin is a MIME type handler.
69 virtual bool HandleDocumentLoad(const pp::URLLoader& url_loader); 69 bool HandleDocumentLoad(const pp::URLLoader& url_loader) override;
70 70
71 // Load support. 71 // Load support.
72 // 72 //
73 // Starts NaCl module but does not wait until low-level 73 // Starts NaCl module but does not wait until low-level
74 // initialization (e.g. ld.so dynamic loading of manifest files) is 74 // initialization (e.g. ld.so dynamic loading of manifest files) is
75 // done. The module will become ready later, asynchronously. Other 75 // done. The module will become ready later, asynchronously. Other
76 // event handlers should block until the module is ready before 76 // event handlers should block until the module is ready before
77 // trying to communicate with it, i.e., until nacl_ready_state is 77 // trying to communicate with it, i.e., until nacl_ready_state is
78 // DONE. 78 // DONE.
79 // 79 //
(...skipping 21 matching lines...) Expand all
101 101
102 nacl::DescWrapperFactory* wrapper_factory() const { return wrapper_factory_; } 102 nacl::DescWrapperFactory* wrapper_factory() const { return wrapper_factory_; }
103 103
104 const PPB_NaCl_Private* nacl_interface() const { return nacl_interface_; } 104 const PPB_NaCl_Private* nacl_interface() const { return nacl_interface_; }
105 pp::UMAPrivate& uma_interface() { return uma_interface_; } 105 pp::UMAPrivate& uma_interface() { return uma_interface_; }
106 106
107 private: 107 private:
108 NACL_DISALLOW_COPY_AND_ASSIGN(Plugin); 108 NACL_DISALLOW_COPY_AND_ASSIGN(Plugin);
109 // The browser will invoke the destructor via the pp::Instance 109 // The browser will invoke the destructor via the pp::Instance
110 // pointer to this object, not from base's Delete(). 110 // pointer to this object, not from base's Delete().
111 ~Plugin(); 111 ~Plugin() override;
112 112
113 // Shuts down socket connection, service runtime, and receive thread, 113 // Shuts down socket connection, service runtime, and receive thread,
114 // in this order, for the main nacl subprocess. 114 // in this order, for the main nacl subprocess.
115 void ShutDownSubprocesses(); 115 void ShutDownSubprocesses();
116 116
117 // Histogram helper functions, internal to Plugin so they can use 117 // Histogram helper functions, internal to Plugin so they can use
118 // uma_interface_ normally. 118 // uma_interface_ normally.
119 void HistogramTimeSmall(const std::string& name, int64_t ms); 119 void HistogramTimeSmall(const std::string& name, int64_t ms);
120 120
121 // Loads and starts a helper (e.g. llc, ld) NaCl module. 121 // Loads and starts a helper (e.g. llc, ld) NaCl module.
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after
178 178
179 PP_NaClFileInfo nexe_file_info_; 179 PP_NaClFileInfo nexe_file_info_;
180 180
181 const PPB_NaCl_Private* nacl_interface_; 181 const PPB_NaCl_Private* nacl_interface_;
182 pp::UMAPrivate uma_interface_; 182 pp::UMAPrivate uma_interface_;
183 }; 183 };
184 184
185 } // namespace plugin 185 } // namespace plugin
186 186
187 #endif // NATIVE_CLIENT_SRC_TRUSTED_PLUGIN_PLUGIN_H_ 187 #endif // NATIVE_CLIENT_SRC_TRUSTED_PLUGIN_PLUGIN_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698