prime/include/GuiSys/CGuiSys.hpp

54 lines
1009 B
C++
Raw Normal View History

#ifndef _CGUISYS
#define _CGUISYS
#include "types.h"
2022-12-31 19:59:30 +00:00
#include "rstl/rc_ptr.hpp"
#include "rstl/single_ptr.hpp"
#include "GuiSys/CGuiTextSupport.hpp"
class IFactory;
class CSimplePool;
2022-12-31 19:59:30 +00:00
class CTextExecuteBuffer;
class CTextParser;
class CGuiWidget;
2022-10-01 06:19:09 +00:00
class CGuiSys;
extern CGuiSys* gGuiSystem;
class CGuiSys {
2022-12-31 19:59:30 +00:00
public:
enum EUsageMode {
kUM_Zero,
kUM_One,
kUM_Two,
};
CGuiSys(IFactory*, CSimplePool*, EUsageMode);
2022-10-01 06:19:09 +00:00
~CGuiSys();
static void SetGlobalGuiSys(CGuiSys* ptr) {
gGuiSystem = ptr;
spGuiSys = ptr;
}
2022-12-31 19:59:30 +00:00
static CGuiWidget* CreateWidgetInGame(uint type, CInputStream& in,
CGuiFrame* parent);
2022-12-31 19:59:30 +00:00
void AddFactories(EUsageMode mode);
2022-10-01 06:19:09 +00:00
2022-12-31 19:59:30 +00:00
private:
IFactory* x0_resFactory;
CSimplePool* x4_resStore;
EUsageMode x8_mode;
rstl::single_ptr< CTextExecuteBuffer > xc_textExecuteBuffer;
rstl::single_ptr< CTextParser > x10_textParser;
2022-10-01 06:19:09 +00:00
static CGuiSys* spGuiSys;
};
2022-12-31 19:59:30 +00:00
CHECK_SIZEOF(CGuiSys, 0x14);
#endif // _CGUISYS