- Timestamp:
- May 24, 2015, 11:19:15 PM (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/core7/src/libraries/core/singleton/Scope.h
r10458 r10460 76 76 template <ScopeID::Value scope> 77 77 friend class Scope; 78 friend class S copeListener;78 friend class StaticallyInitializedScopedSingletonWrapper; 79 79 80 80 private: … … 95 95 96 96 protected: 97 //! Constructor: Registers the instance. 98 ScopeListener(ScopeID::Value scope) : scope_(scope), bActivated_(false) 99 { ScopeManager::getListeners()[this->scope_].insert(this); } 100 //! Destructor: Unregisters the instance. 101 virtual ~ScopeListener() 102 { ScopeManager::getListeners()[this->scope_].erase(this); } 97 ScopeListener(ScopeID::Value scope) : scope_(scope), bActivated_(false) { } 98 virtual ~ScopeListener() { } 103 99 104 100 //! Gets called if the scope is activated … … 106 102 //! Gets called if the scope is deactivated 107 103 virtual void deactivated() = 0; 104 105 public: 106 inline ScopeID::Value getScope() const 107 { return this->scope_; } 108 108 109 109 private:
Note: See TracChangeset
for help on using the changeset viewer.