| OLD | NEW |
| 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_SHARED_IMPL_TEST_GLOBALS_H_ | 5 #ifndef PPAPI_SHARED_IMPL_TEST_GLOBALS_H_ |
| 6 #define PPAPI_SHARED_IMPL_TEST_GLOBALS_H_ | 6 #define PPAPI_SHARED_IMPL_TEST_GLOBALS_H_ |
| 7 | 7 |
| 8 #include "base/compiler_specific.h" | 8 #include "base/compiler_specific.h" |
| 9 #include "ppapi/shared_impl/callback_tracker.h" | 9 #include "ppapi/shared_impl/callback_tracker.h" |
| 10 #include "ppapi/shared_impl/ppapi_globals.h" | 10 #include "ppapi/shared_impl/ppapi_globals.h" |
| (...skipping 11 matching lines...) Expand all Loading... |
| 22 } | 22 } |
| 23 virtual void DidDeleteInstance(PP_Instance instance) OVERRIDE { | 23 virtual void DidDeleteInstance(PP_Instance instance) OVERRIDE { |
| 24 } | 24 } |
| 25 }; | 25 }; |
| 26 | 26 |
| 27 // Implementation of PpapiGlobals for tests that don't need either the host- or | 27 // Implementation of PpapiGlobals for tests that don't need either the host- or |
| 28 // plugin-specific implementations. | 28 // plugin-specific implementations. |
| 29 class TestGlobals : public PpapiGlobals { | 29 class TestGlobals : public PpapiGlobals { |
| 30 public: | 30 public: |
| 31 TestGlobals(); | 31 TestGlobals(); |
| 32 TestGlobals(PpapiGlobals::ForTest); | 32 TestGlobals(PpapiGlobals::ForPerThreadTest); |
| 33 virtual ~TestGlobals(); | 33 virtual ~TestGlobals(); |
| 34 | 34 |
| 35 // PpapiGlobals implementation. | 35 // PpapiGlobals implementation. |
| 36 virtual ResourceTracker* GetResourceTracker() OVERRIDE; | 36 virtual ResourceTracker* GetResourceTracker() OVERRIDE; |
| 37 virtual VarTracker* GetVarTracker() OVERRIDE; | 37 virtual VarTracker* GetVarTracker() OVERRIDE; |
| 38 virtual CallbackTracker* GetCallbackTrackerForInstance( | 38 virtual CallbackTracker* GetCallbackTrackerForInstance( |
| 39 PP_Instance instance) OVERRIDE; | 39 PP_Instance instance) OVERRIDE; |
| 40 virtual thunk::PPB_Instance_API* GetInstanceAPI( | 40 virtual thunk::PPB_Instance_API* GetInstanceAPI( |
| 41 PP_Instance instance) OVERRIDE; | 41 PP_Instance instance) OVERRIDE; |
| 42 virtual thunk::ResourceCreationAPI* GetResourceCreationAPI( | 42 virtual thunk::ResourceCreationAPI* GetResourceCreationAPI( |
| (...skipping 19 matching lines...) Expand all Loading... |
| 62 ResourceTracker resource_tracker_; | 62 ResourceTracker resource_tracker_; |
| 63 TestVarTracker var_tracker_; | 63 TestVarTracker var_tracker_; |
| 64 scoped_refptr<CallbackTracker> callback_tracker_; | 64 scoped_refptr<CallbackTracker> callback_tracker_; |
| 65 | 65 |
| 66 DISALLOW_COPY_AND_ASSIGN(TestGlobals); | 66 DISALLOW_COPY_AND_ASSIGN(TestGlobals); |
| 67 }; | 67 }; |
| 68 | 68 |
| 69 } // namespace ppapi | 69 } // namespace ppapi |
| 70 | 70 |
| 71 #endif // PPAPI_SHARED_IMPL_TEST_GLOBALS_H_ | 71 #endif // PPAPI_SHARED_IMPL_TEST_GLOBALS_H_ |
| OLD | NEW |