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

Side by Side Diff: native_client_sdk/src/tests/nacl_io_test/fake_resource_manager.h

Issue 137853023: [NaCl SDK] nacl_io: Add new fakes (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 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 LIBRARIES_NACL_IO_TEST_FAKE_RESOURCE_MANAGER_H_ 5 #ifndef TESTS_NACL_IO_TEST_FAKE_RESOURCE_MANAGER_H_
6 #define LIBRARIES_NACL_IO_TEST_FAKE_RESOURCE_MANAGER_H_ 6 #define TESTS_NACL_IO_TEST_FAKE_RESOURCE_MANAGER_H_
7 7
8 #include <map> 8 #include <map>
9 9
10 #include <ppapi/c/pp_resource.h> 10 #include <ppapi/c/pp_resource.h>
11 11
12 #include "sdk_util/atomicops.h" 12 #include "sdk_util/atomicops.h"
13 #include "sdk_util/macros.h" 13 #include "sdk_util/macros.h"
14 #include "sdk_util/simple_lock.h" 14 #include "sdk_util/simple_lock.h"
15 15
16 class FakeResource; 16 class FakeResource;
(...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after
103 }; 103 };
104 104
105 template <typename T> 105 template <typename T>
106 inline T* FakeResourceManager::Get(PP_Resource handle) { 106 inline T* FakeResourceManager::Get(PP_Resource handle) {
107 return Get(handle)->resource<T>(); 107 return Get(handle)->resource<T>();
108 } 108 }
109 109
110 #define CREATE_RESOURCE(MANAGER, TYPE, RESOURCE) \ 110 #define CREATE_RESOURCE(MANAGER, TYPE, RESOURCE) \
111 (MANAGER)->Create((RESOURCE), #TYPE, __FILE__, __LINE__) 111 (MANAGER)->Create((RESOURCE), #TYPE, __FILE__, __LINE__)
112 112
113 #endif // LIBRARIES_NACL_IO_TEST_FAKE_RESOURCE_MANAGER_H_ 113 #endif // TESTS_NACL_IO_TEST_FAKE_RESOURCE_MANAGER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698