Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Aug 19, 2009, 12:19:11 AM (16 years ago)
Author:
rgrieder
Message:

Cleaned out the lua script files for the GUI.
Also replaced "require" function to support resources.
Fixed a problem with the return value of doFile, includeFile and require being discarded because the tolua binding is for a C++ function returning void.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • code/branches/resource2/src/core/GUIManager.h

    r5651 r5661  
    2828 */
    2929
    30 /**
    31 @file
    32 @brief
    33     Declaration of the GUIManager class.
    34 */
    35 
    3630#ifndef _GUIManager_H__
    3731#define _GUIManager_H__
     
    4337#include <CEGUIForwardRefs.h>
    4438#include <boost/scoped_ptr.hpp>
     39#include <boost/shared_ptr.hpp>
    4540
    4641#include "util/OgreForwardRefs.h"
     
    8075        GUIManager(const GUIManager& instance); //!< private and undefined copy c'tor (this is a singleton class)
    8176
    82         void loadLuaCode();
    83 
    8477        // keyHandler functions
    8578        void keyPressed (const KeyEvent& evt);
     
    9386
    9487        scoped_ptr<CEGUI::OgreCEGUIRenderer> guiRenderer_;  //!< CEGUI's interface to the Ogre Engine
     88        scoped_ptr<LuaState>                 luaState_;     //!< LuaState, access point to the Lua engine
    9589        scoped_ptr<CEGUI::LuaScriptModule>   scriptModule_; //!< CEGUI's script module to use Lua
    9690        scoped_ptr<CEGUI::System>            guiSystem_;    //!< CEGUI's main system
     91        shared_ptr<ResourceInfo>             rootFileInfo_; //!< Resource information about the root script
    9792        Ogre::RenderWindow*      renderWindow_;     //!< Ogre's render window to give CEGUI access to it
    9893        CEGUI::ResourceProvider* resourceProvider_; //!< CEGUI's resource provider
    9994        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
    10195
    10296        static GUIManager*       singletonPtr_s;    //!< Singleton reference to GUIManager
Note: See TracChangeset for help on using the changeset viewer.