fix: RTC warning not being shown (#5209)

This commit is contained in:
Peter Feerick
2024-06-23 18:46:53 +10:00
committed by GitHub
parent 0d6d35ef02
commit 22114a67fa
4 changed files with 13 additions and 9 deletions
+6 -4
View File
@@ -61,6 +61,8 @@ RadioHardwarePage::RadioHardwarePage() :
enableVBatBridge();
}
void RadioHardwarePage::checkEvents() { enableVBatBridge(); }
void RadioHardwarePage::cleanup()
{
disableVBatBridge();
@@ -134,11 +136,11 @@ static SetupLineDef setupLines[] = {
GET_SET_INVERTED(g_eeGeneral.disableRtcWarning));
// RTC Batt display
std::string s(STR_VALUE);
s += " ";
new DynamicNumber<uint16_t>(
parent, {x + ToggleSwitch::TOGGLE_W + PAD_SMALL, y + PAD_SMALL + 1, 0, 0}, [] { return getRTCBatteryVoltage(); },
COLOR_THEME_PRIMARY1 | PREC2, s.c_str(), "V");
parent,
{x + ToggleSwitch::TOGGLE_W + PAD_LARGE, y + PAD_SMALL + 1, 0, 0},
[] { return getRTCBatteryVoltage(); }, COLOR_THEME_PRIMARY1 | PREC2,
"", "V");
}
},
{
+2
View File
@@ -25,6 +25,8 @@
class RadioHardwarePage : public PageTab
{
void checkEvents() override;
public:
RadioHardwarePage();