From: Melissa LeBlanc-Williams Date: Thu, 28 Sep 2023 21:50:48 +0000 (-0700) Subject: Make some internal functions protected X-Git-Tag: 1.0.0^2~6 X-Git-Url: https://git.ayoreis.com/hackapet/Adafruit_Blinka_Displayio.git/commitdiff_plain/11e8cc62b210c761fd42e6cca723835654811776 Make some internal functions protected --- diff --git a/displayio/__init__.py b/displayio/__init__.py index fad9122..55bb1d5 100644 --- a/displayio/__init__.py +++ b/displayio/__init__.py @@ -45,7 +45,7 @@ def _background(): """Main thread function to loop through all displays and update them""" while True: for display in displays: - display.background() + display._background() # pylint: disable=protected-access def release_displays() -> None: @@ -55,7 +55,7 @@ def release_displays() -> None: initialization so the display is active as long as possible. """ for display in displays: - display.release() + display._release() # pylint: disable=protected-access displays.clear() for display_bus in display_buses: diff --git a/displayio/_display.py b/displayio/_display.py index 2a6ea7b..f2d02cf 100644 --- a/displayio/_display.py +++ b/displayio/_display.py @@ -327,7 +327,7 @@ class Display: ) return areas - def background(self): + def _background(self): """Run background refresh tasks. Do not call directly""" if ( self._auto_refresh @@ -427,12 +427,12 @@ class Display: self._core.fill_area(area, mask, buffer) return buffer - def release(self) -> None: + def _release(self) -> None: """Release the display and free its resources""" self.auto_refresh = False self._core.release_display_core() - def reset(self) -> None: + def _reset(self) -> None: """Reset the display""" self.auto_refresh = True circuitpython_splash.x = 0