aboutsummaryrefslogtreecommitdiff
path: root/src/game/status_manager.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/game/status_manager.hpp')
-rw-r--r--src/game/status_manager.hpp32
1 files changed, 32 insertions, 0 deletions
diff --git a/src/game/status_manager.hpp b/src/game/status_manager.hpp
new file mode 100644
index 0000000..62b5bc7
--- /dev/null
+++ b/src/game/status_manager.hpp
@@ -0,0 +1,32 @@
+#pragma once
+
+#include "interfaces/generation_tracker.hpp"
+#include "interfaces/status_manager.hpp"
+#include "interfaces/statusline.hpp"
+#include "interfaces/subscriber.hpp"
+
+#include "engine/data/vector2.hpp"
+
+#include <memory>
+#include <unordered_map>
+
+class StatusManager : public IStatusManager
+{
+public:
+ explicit StatusManager(std::shared_ptr<IStatusLine> statusline) noexcept;
+
+ void set_section_title(
+ const StatusLineSection &section,
+ const std::string_view &title
+ ) noexcept override;
+
+ void set_section_body(
+ const StatusLineSection &section,
+ const std::string_view &body
+ ) noexcept override;
+
+private:
+ std::shared_ptr<IStatusLine> _statusline;
+
+ std::unordered_map<StatusLineSection, std::size_t> _title_lengths;
+};