summaryrefslogtreecommitdiff
path: root/src/displayapp/screens/Label.cpp
diff options
context:
space:
mode:
authorJF002 <JF002@users.noreply.github.com>2020-10-04 12:21:22 +0200
committerGitHub <noreply@github.com>2020-10-04 12:21:22 +0200
commit39954bbd3afb592a0c3109e3479594183e8d0778 (patch)
tree58efd04aa38b8dc7989c51fe3c9cdb9a3fb46a54 /src/displayapp/screens/Label.cpp
parent5adc97702c326d0252df6da75ce4ac244a4b3553 (diff)
parent6c86d1d9d706706fcb6f214aba8259e61ed68755 (diff)
Merge pull request #68 from Avamander/patch-1
Rename folders to follow a consistent style
Diffstat (limited to 'src/displayapp/screens/Label.cpp')
-rw-r--r--src/displayapp/screens/Label.cpp15
1 files changed, 15 insertions, 0 deletions
diff --git a/src/displayapp/screens/Label.cpp b/src/displayapp/screens/Label.cpp
new file mode 100644
index 00000000..780ee88e
--- /dev/null
+++ b/src/displayapp/screens/Label.cpp
@@ -0,0 +1,15 @@
+#include <libs/lvgl/lvgl.h>
+#include "Label.h"
+
+using namespace Pinetime::Applications::Screens;
+
+Label::Label(Pinetime::Applications::DisplayApp *app, const char *text) : Screen(app), text{text} {
+ label = lv_label_create(lv_scr_act(), NULL);
+ lv_label_set_align(label, LV_LABEL_ALIGN_LEFT);
+ lv_obj_set_size(label, 240, 240);
+ lv_label_set_text(label, text);
+}
+
+Label::~Label() {
+ lv_obj_clean(lv_scr_act());
+}