From fb99520c988f452dad7dc07751d2261f09c4b791 Mon Sep 17 00:00:00 2001 From: JF Date: Sat, 18 Jan 2020 14:50:24 +0100 Subject: Add version (major.minor.patch) in CMake files. Display the version on the display. --- src/DisplayApp/DisplayApp.cpp | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'src/DisplayApp/DisplayApp.cpp') diff --git a/src/DisplayApp/DisplayApp.cpp b/src/DisplayApp/DisplayApp.cpp index fe7e68dc..f37cee98 100644 --- a/src/DisplayApp/DisplayApp.cpp +++ b/src/DisplayApp/DisplayApp.cpp @@ -12,6 +12,7 @@ #include #include #include +#include "../Version.h" using namespace Pinetime::Applications; @@ -105,6 +106,11 @@ void DisplayApp::InitHw() { gfx->DrawString(10, 0, 0x0000, "BLE", &smallFont, false); gfx->DrawString(20, 180, 0xffff, "", &smallFont, false); + char version[20]; + sprintf(version, "VERSION: %d.%d.%d", Version::Major(), Version::Minor(), Version::Patch()); + gfx->DrawString(20, 220, 0xffff, version, &smallFont, false); + + currentChar[0] = 0; currentChar[1] = 0; currentChar[2] = 0; -- cgit v1.2.3-70-g09d2