| OLD | NEW |
| (Empty) |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | |
| 2 // Use of this source code is governed by a BSD-style license that can be | |
| 3 // found in the LICENSE file. | |
| 4 | |
| 5 #ifndef PPAPI_SHARED_IMPL_PPAPI_GLOBALS_H_ | |
| 6 #define PPAPI_SHARED_IMPL_PPAPI_GLOBALS_H_ | |
| 7 | |
| 8 #include "base/basictypes.h" | |
| 9 | |
| 10 namespace ppapi { | |
| 11 | |
| 12 class ResourceTracker; | |
| 13 class VarTracker; | |
| 14 | |
| 15 // Abstract base class | |
| 16 class PpapiGlobals { | |
| 17 public: | |
| 18 PpapiGlobals(); | |
| 19 virtual ~PpapiGlobals(); | |
| 20 | |
| 21 // Getter for the global singleton. | |
| 22 inline static PpapiGlobals* Get() { return ppapi_globals_; } | |
| 23 | |
| 24 virtual ResourceTracker* GetResourceTracker() = 0; | |
| 25 virtual VarTracker* GetVarTracker() = 0; | |
| 26 | |
| 27 private: | |
| 28 static PpapiGlobals* ppapi_globals_; | |
| 29 | |
| 30 DISALLOW_COPY_AND_ASSIGN(PpapiGlobals); | |
| 31 }; | |
| 32 | |
| 33 } // namespace ppapi | |
| 34 | |
| 35 #endif // PPAPI_SHARED_IMPL_PPAPI_GLOBALS_H_ | |
| OLD | NEW |