2024-02-18 23:08:03 +00:00
|
|
|
#pragma once
|
|
|
|
|
|
|
|
|
|
#include "IWidget.hpp"
|
|
|
|
|
#include "../../helpers/Vector2D.hpp"
|
2024-02-19 20:50:58 +00:00
|
|
|
#include "../../helpers/Color.hpp"
|
2024-02-18 23:08:03 +00:00
|
|
|
#include <string>
|
|
|
|
|
|
|
|
|
|
struct SPreloadedAsset;
|
|
|
|
|
|
|
|
|
|
class CBackground : public IWidget {
|
|
|
|
|
public:
|
2024-02-19 20:50:58 +00:00
|
|
|
CBackground(const Vector2D& viewport, const std::string& resourceID, const CColor& color);
|
2024-02-18 23:08:03 +00:00
|
|
|
|
2024-02-19 16:26:08 +00:00
|
|
|
virtual bool draw(const SRenderData& data);
|
2024-02-18 23:08:03 +00:00
|
|
|
|
|
|
|
|
private:
|
|
|
|
|
Vector2D viewport;
|
|
|
|
|
std::string resourceID;
|
2024-02-19 20:50:58 +00:00
|
|
|
CColor color;
|
2024-02-18 23:08:03 +00:00
|
|
|
SPreloadedAsset* asset = nullptr;
|
|
|
|
|
};
|