mirror of
https://github.com/MarekZegare4/MeshCore-Solo.git
synced 2026-11-01 10:21:59 +00:00
fix(ui-new): the screen redraws when USB power comes or goes
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Sonnet 5.5
parent
6e13ad59ae
commit
f396882768
@@ -3327,6 +3327,11 @@ void UITask::loop() {
|
||||
|
||||
if (curr) curr->poll();
|
||||
|
||||
// A cable plugged in or pulled out: redraw at once, so the bolt by the
|
||||
// battery follows it instead of waiting for the screen's next refresh.
|
||||
{ static bool ext = board.isExternalPowered();
|
||||
const bool now = board.isExternalPowered();
|
||||
if (now != ext) { ext = now; _next_refresh = 0; } }
|
||||
|
||||
if (_display != NULL && _display->isOn()) {
|
||||
// Lock-screen password prompt
|
||||
|
||||
Reference in New Issue
Block a user