Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Aug 29, 2009, 10:19:38 PM (15 years ago)
Author:
landauf
Message:

merged libraries branch back to trunk

Location:
code/trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • code/trunk

  • code/trunk/src/core/GUIManager.h

    r3370 r5693  
    5050namespace orxonox
    5151{
     52    class PlayerInfo; // Forward declaration
     53
    5254    /**
    5355    @class GUIManager
     
    7779        static GUIManager* getInstancePtr() { return singletonPtr_s; }
    7880
     81        inline void setPlayer(const std::string& guiname, PlayerInfo* player)
     82            { this->players_[guiname] = player; }
     83        inline PlayerInfo* getPlayer(const std::string& guiname) const
     84            { std::map<std::string, PlayerInfo*>::const_iterator it = this->players_.find(guiname); return (it != this->players_.end()) ? it->second : 0; }
     85
    7986    private:
    8087        GUIManager(const GUIManager& instance); //!< private and undefined copy c'tor (this is a singleton class)
     
    9299        void mouseScrolled (int abs, int rel);
    93100
    94         boost::scoped_ptr<CEGUI::OgreCEGUIRenderer> guiRenderer_;  //!< CEGUI's interface to the Ogre Engine
    95         boost::scoped_ptr<CEGUI::LuaScriptModule>   scriptModule_; //!< CEGUI's script module to use Lua
    96         boost::scoped_ptr<CEGUI::System>            guiSystem_;    //!< CEGUI's main system
    97         Ogre::RenderWindow*      renderWindow_;     //!< Ogre's render window to give CEGUI access to it
    98         CEGUI::ResourceProvider* resourceProvider_; //!< CEGUI's resource provider
    99         CEGUI::Logger*           ceguiLogger_;      //!< CEGUI's logger to be able to log CEGUI errors in our log
    100         lua_State*               luaState_;         //!< Lua state, access point to the Lua engine
     101        boost::scoped_ptr<CEGUI::OgreCEGUIRenderer> guiRenderer_;       //!< CEGUI's interface to the Ogre Engine
     102        boost::scoped_ptr<CEGUI::LuaScriptModule>   scriptModule_;      //!< CEGUI's script module to use Lua
     103        boost::scoped_ptr<CEGUI::System>            guiSystem_;         //!< CEGUI's main system
     104        Ogre::RenderWindow*                         renderWindow_;      //!< Ogre's render window to give CEGUI access to it
     105        CEGUI::ResourceProvider*                    resourceProvider_;  //!< CEGUI's resource provider
     106        CEGUI::Logger*                              ceguiLogger_;       //!< CEGUI's logger to be able to log CEGUI errors in our log
     107        lua_State*                                  luaState_;          //!< Lua state, access point to the Lua engine
     108        std::map<std::string, PlayerInfo*>          players_;           //!< Stores the player (owner) for each gui
    101109
    102         static GUIManager*       singletonPtr_s;    //!< Singleton reference to GUIManager
     110        static GUIManager*                          singletonPtr_s;     //!< Singleton reference to GUIManager
    103111
    104112    };
Note: See TracChangeset for help on using the changeset viewer.