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

Side by Side Diff: ppapi/thunk/enter.h

Issue 10831015: Pass large object by const ref (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 5 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 PPAPI_THUNK_ENTER_H_ 5 #ifndef PPAPI_THUNK_ENTER_H_
6 #define PPAPI_THUNK_ENTER_H_ 6 #define PPAPI_THUNK_ENTER_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
(...skipping 185 matching lines...) Expand 10 before | Expand all | Expand 10 after
196 196
197 // ---------------------------------------------------------------------------- 197 // ----------------------------------------------------------------------------
198 198
199 // Like EnterResource but assumes the lock is already held. 199 // Like EnterResource but assumes the lock is already held.
200 template<typename ResourceT> 200 template<typename ResourceT>
201 class EnterResourceNoLock : public EnterResource<ResourceT, false> { 201 class EnterResourceNoLock : public EnterResource<ResourceT, false> {
202 public: 202 public:
203 EnterResourceNoLock(PP_Resource resource, bool report_error) 203 EnterResourceNoLock(PP_Resource resource, bool report_error)
204 : EnterResource<ResourceT, false>(resource, report_error) { 204 : EnterResource<ResourceT, false>(resource, report_error) {
205 } 205 }
206 EnterResourceNoLock(PP_Resource resource, PP_CompletionCallback callback, 206 EnterResourceNoLock(PP_Resource resource,
207 const PP_CompletionCallback& callback,
207 bool report_error) 208 bool report_error)
208 : EnterResource<ResourceT, false>(resource, callback, report_error) { 209 : EnterResource<ResourceT, false>(resource, callback, report_error) {
209 } 210 }
210 }; 211 };
211 212
212 // EnterInstance --------------------------------------------------------------- 213 // EnterInstance ---------------------------------------------------------------
213 214
214 class PPAPI_THUNK_EXPORT EnterInstance 215 class PPAPI_THUNK_EXPORT EnterInstance
215 : public subtle::EnterBase, 216 : public subtle::EnterBase,
216 public subtle::LockOnEntry<true> { 217 public subtle::LockOnEntry<true> {
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after
269 ResourceCreationAPI* functions() { return functions_; } 270 ResourceCreationAPI* functions() { return functions_; }
270 271
271 private: 272 private:
272 ResourceCreationAPI* functions_; 273 ResourceCreationAPI* functions_;
273 }; 274 };
274 275
275 } // namespace thunk 276 } // namespace thunk
276 } // namespace ppapi 277 } // namespace ppapi
277 278
278 #endif // PPAPI_THUNK_ENTER_H_ 279 #endif // PPAPI_THUNK_ENTER_H_
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698