From ef616178ea932c8a5c357c20e746527b69ed6bb5 Mon Sep 17 00:00:00 2001 From: 0xFEEDC0DE64 Date: Thu, 28 Nov 2024 14:08:34 +0100 Subject: [PATCH] Add demo mode and easteregg color to about page --- evcharger-app/qml/AboutPage.qml | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) diff --git a/evcharger-app/qml/AboutPage.qml b/evcharger-app/qml/AboutPage.qml index 001c0ce..7d11257 100644 --- a/evcharger-app/qml/AboutPage.qml +++ b/evcharger-app/qml/AboutPage.qml @@ -1,6 +1,7 @@ import QtQuick import QtQuick.Controls import QtQuick.Layouts +import EVChargerApp NavigationPage { title: qsTr("About") @@ -29,4 +30,31 @@ NavigationPage { } } } + GeneralOnOffSwitch { + apiKey: "demo" + text: qsTr("Enable demo mode") + visible: true + } + WhiteItemDelegate { + SendMessageHelper { + id: setChargingColor + deviceConnection: theDeviceConnection + } + + text: qsTr("Set charging color to new") + + onClicked: setChargingColor.sendMessage({ + type: "setValue", + key: "cch", + value: "#FEFEFE" + }) + + BusyIndicator { + visible: setChargingColor.pending + } + + RequestStatusText { + request: setChargingColor + } + } }