Skip to content

Commit e1f96af

Browse files
committed
fix use of auto_refresh property during display update
1 parent c8cbc43 commit e1f96af

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

adafruit_pybadger/pybadger_base.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -643,10 +643,12 @@ def show_badge(
643643
self.show(group)
644644

645645
def show(self, group) -> None:
646+
"""Show the given group, refreshing the screen immediately"""
647+
self.activity()
648+
self.display.auto_refresh = False
646649
self.display.show(group)
647-
self.auto_refresh = False
648650
self.display.refresh()
649-
self.activity()
651+
self.display.auto_refresh = True
650652

651653
def show_terminal(self) -> None:
652654
"""Revert to terminalio screen."""

0 commit comments

Comments
 (0)