summaryrefslogtreecommitdiff
path: root/src/DisplayApp/Screens/Modal.cpp
diff options
context:
space:
mode:
authorJF <jf@codingfield.com>2020-03-02 20:12:46 +0100
committerJF <jf@codingfield.com>2020-03-02 20:12:46 +0100
commit824b8a7ebd0e8b4f876dd12f564e89238a1bb1b4 (patch)
tree71d8177a08ba677a5e7aafb790b174f2b4b52b5f /src/DisplayApp/Screens/Modal.cpp
parentdccef161805171a9271ab3ebe50d0cc261c53a65 (diff)
Move version display from Clock screen to the modal window (accessible from tile menu)
Diffstat (limited to 'src/DisplayApp/Screens/Modal.cpp')
-rw-r--r--src/DisplayApp/Screens/Modal.cpp7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/DisplayApp/Screens/Modal.cpp b/src/DisplayApp/Screens/Modal.cpp
index 7a0264e3..fc353c49 100644
--- a/src/DisplayApp/Screens/Modal.cpp
+++ b/src/DisplayApp/Screens/Modal.cpp
@@ -36,12 +36,15 @@ void Modal::Show() {
lv_obj_set_size(obj, LV_HOR_RES, LV_VER_RES);
lv_obj_set_opa_scale_enable(obj, true); /* Enable opacity scaling for the animation */
- static const char * btns2[] = {"Ok", "Cancel", ""};
+ static const char * btns2[] = {"Ok", ""};
/* Create the message box as a child of the modal background */
mbox = lv_mbox_create(obj, NULL);
lv_mbox_add_btns(mbox, btns2);
- lv_mbox_set_text(mbox, "Hello world!");
+ char versionStr[20];
+ sprintf(versionStr, "VERSION: %d.%d.%d", Version::Major(), Version::Minor(), Version::Patch());
+ lv_mbox_set_text(mbox, versionStr);
+// lv_mbox_set_text(mbox, "Hello world!");
lv_obj_align(mbox, NULL, LV_ALIGN_CENTER, 0, 0);
lv_obj_set_event_cb(mbox, Modal::mbox_event_cb);