Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Oct 1, 2009, 11:44:53 AM (15 years ago)
Author:
rgrieder
Message:

Moved the singleton creation/destruction mess to the Core class by using just two possible Scopes:

  • ScopeID::Root for singletons that may always persists
  • ScopeID::Graphics for singletons that only work when graphics was loaded
File:
1 edited

Legend:

Unmodified
Added
Removed
  • code/branches/core5/src/modules/questsystem/QuestManager.h

    r5760 r5850  
    5050namespace orxonox
    5151{
    52 
    53     typedef ScopedSingleton<QuestManager, ScopeID::GSLevel> ScopedSingletonQuestManagerGSLevel; // workaround for tolua
    54 
    5552    /**
    5653    @brief
     
    6057        Damian 'Mozork' Frick
    6158    */
    62     class _QuestsystemExport QuestManager : public ScopedSingletonQuestManagerGSLevel, public orxonox::OrxonoxClass
    63     {
     59    class _QuestsystemExport QuestManager
    6460// tolua_end
     61        : public ScopedSingleton<QuestManager, ScopeID::Root>, public orxonox::OrxonoxClass
     62    { // tolua_export
    6563
    66             friend class ScopedSingleton<QuestManager, ScopeID::GSLevel>;
     64            friend class ScopedSingleton<QuestManager, ScopeID::Root>;
    6765            friend class QuestGUI;
    6866
     
    7270
    7371            //! Returns a reference to the single instance of the Quest Manager.
    74             static QuestManager& getInstance() { return ScopedSingleton<QuestManager, ScopeID::GSLevel>::getInstance(); } // tolua_export
     72            static QuestManager& getInstance() { return ScopedSingleton<QuestManager, ScopeID::Root>::getInstance(); } // tolua_export
    7573
    7674            //! Retreive the main window for the GUI.
Note: See TracChangeset for help on using the changeset viewer.