From dabd04fa47f8203c78250d15eaef337e070ecde2 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Horv=C3=A1th=20=C3=81d=C3=A1m?=
 <horvath.adam.7@hallgato.ppke.hu>
Date: Mon, 20 May 2024 00:04:06 +0000
Subject: [PATCH] =?UTF-8?q?lehet=20v=C3=A9gleges?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

---
 checkbox.hpp | 28 ++++++++++++++++++++++++++++
 1 file changed, 28 insertions(+)
 create mode 100644 checkbox.hpp

diff --git a/checkbox.hpp b/checkbox.hpp
new file mode 100644
index 0000000..e7ba421
--- /dev/null
+++ b/checkbox.hpp
@@ -0,0 +1,28 @@
+#ifndef CHECKBOX_HPP_INCLUDED
+#define CHECKBOX_HPP_INCLUDED
+
+#include "widgets.hpp"
+#include "application.hpp"
+
+class CheckBox : public Widget {
+private:
+    bool _checked;
+    int _value;
+    int playerValue;
+
+public:
+    CheckBox(Application *parent, int x, int y, int sx, int sy);
+
+    void draw() override;
+    void handle(genv::event ev) override;
+    bool is_checked() override;
+    void value(int) override;
+    int value_sz() override;
+    int getPlayerValue() const override;
+private:
+    void drawCross(int x, int y, int width, int height, int r, int g, int b);
+    void drawCircle(int x, int y, int radius, int r, int g, int b);
+
+};
+
+#endif // CHECKBOX_HPP_INCLUDED
-- 
GitLab