|
@@ -125,8 +125,6 @@ class CGStatusBar : public CLabel, public std::enable_shared_from_this<CGStatusB
|
|
|
std::string consoleText;
|
|
std::string consoleText;
|
|
|
bool enteringText;
|
|
bool enteringText;
|
|
|
|
|
|
|
|
- void init();
|
|
|
|
|
-
|
|
|
|
|
CGStatusBar(std::shared_ptr<CIntObject> background_, EFonts Font = FONT_SMALL, ETextAlignment Align = ETextAlignment::CENTER, const SDL_Color & Color = Colors::WHITE);
|
|
CGStatusBar(std::shared_ptr<CIntObject> background_, EFonts Font = FONT_SMALL, ETextAlignment Align = ETextAlignment::CENTER, const SDL_Color & Color = Colors::WHITE);
|
|
|
CGStatusBar(int x, int y, std::string name, int maxw = -1);
|
|
CGStatusBar(int x, int y, std::string name, int maxw = -1);
|
|
|
|
|
|
|
@@ -143,15 +141,17 @@ protected:
|
|
|
void clickLeft(tribool down, bool previousState) override;
|
|
void clickLeft(tribool down, bool previousState) override;
|
|
|
|
|
|
|
|
public:
|
|
public:
|
|
|
|
|
+ ~CGStatusBar();
|
|
|
|
|
+
|
|
|
template<typename ...Args>
|
|
template<typename ...Args>
|
|
|
static std::shared_ptr<CGStatusBar> create(Args... args)
|
|
static std::shared_ptr<CGStatusBar> create(Args... args)
|
|
|
{
|
|
{
|
|
|
std::shared_ptr<CGStatusBar> ret{new CGStatusBar{args...}};
|
|
std::shared_ptr<CGStatusBar> ret{new CGStatusBar{args...}};
|
|
|
- ret->init();
|
|
|
|
|
return ret;
|
|
return ret;
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
void show(SDL_Surface * to) override;
|
|
void show(SDL_Surface * to) override;
|
|
|
|
|
+ void activate() override;
|
|
|
void deactivate() override;
|
|
void deactivate() override;
|
|
|
|
|
|
|
|
// IStatusBar interface
|
|
// IStatusBar interface
|