Update src/displayapp/screens/WatchFaceTerminal.cpp

Co-authored-by: NeroBurner <pyro4hell@gmail.com>
This commit is contained in:
Марков Дмитрий 2022-02-02 09:03:29 +05:00 committed by GitHub
parent 471a843909
commit b4669be38b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -125,9 +125,11 @@ void WatchFaceTerminal::Refresh() {
bleState = bleController.IsConnected();
if (bleState.IsUpdated()) {
char bleStr[24];
sprintf(bleStr, "[STAT]#387b54 %s#",bleController.IsConnected() ? "Connected" : "Disconnected");
lv_label_set_text(connectState, bleStr);
if (bleState.Get()) {
lv_label_set_text_static(connectState, "[STAT]#387b54 Connected#");
} else {
lv_label_set_text_static(connectState, "[STAT]#387b54 Disconnected#");
}
}
lv_obj_align(batteryIcon, lv_scr_act(), LV_ALIGN_IN_TOP_RIGHT, -5, 5);