]> git.localhorst.tv Git - blobs.git/blobdiff - src/ui/TimePanel.hpp
track a few things
[blobs.git] / src / ui / TimePanel.hpp
diff --git a/src/ui/TimePanel.hpp b/src/ui/TimePanel.hpp
new file mode 100644 (file)
index 0000000..a150cf3
--- /dev/null
@@ -0,0 +1,42 @@
+#ifndef BLOBS_UI_TIMEPANEL_HPP_
+#define BLOBS_UI_TIMEPANEL_HPP_
+
+#include "Panel.hpp"
+
+
+namespace blobs {
+namespace graphics {
+       class Viewport;
+}
+namespace world {
+       class Body;
+       class Simulation;
+}
+namespace ui {
+
+class Label;
+
+class TimePanel {
+
+public:
+       explicit TimePanel(world::Simulation &);
+       ~TimePanel();
+
+public:
+       void SetBody(world::Body &b) noexcept { body = &b; }
+       void UnsetBody() noexcept { body = nullptr; }
+       void Draw(graphics::Viewport &) noexcept;
+
+private:
+       world::Simulation ∼
+       world::Body *body;
+       Label *time;
+       Label *clock;
+       Panel panel;
+
+};
+
+}
+}
+
+#endif