mirror of
https://github.com/firestar5683/StarPilot.git
synced 2026-08-24 01:33:46 +08:00
updater: new scroller style (#37556)
* good start * reset on push * clean up * why tf it remove comments * no more base unnav * repack
This commit is contained in:
+3
-11
@@ -216,9 +216,11 @@ class DownloadingPage(Widget):
|
||||
))
|
||||
|
||||
|
||||
class FailedPageBase(Widget):
|
||||
class FailedPage(NavWidget):
|
||||
def __init__(self, reboot_callback: Callable, retry_callback: Callable, title: str = "download failed"):
|
||||
super().__init__()
|
||||
self.set_back_callback(retry_callback)
|
||||
|
||||
self._title_label = UnifiedLabel(title, 64, text_color=rl.Color(255, 255, 255, int(255 * 0.9)),
|
||||
font_weight=FontWeight.DISPLAY)
|
||||
self._reason_label = UnifiedLabel("", 36, text_color=rl.Color(255, 255, 255, int(255 * 0.9 * 0.65)),
|
||||
@@ -269,12 +271,6 @@ class FailedPageBase(Widget):
|
||||
))
|
||||
|
||||
|
||||
class FailedPage(FailedPageBase, NavWidget):
|
||||
def __init__(self, reboot_callback: Callable, retry_callback: Callable, title: str = "download failed"):
|
||||
super().__init__(reboot_callback, retry_callback, title)
|
||||
self.set_back_callback(retry_callback)
|
||||
|
||||
|
||||
class GreyBigButton(BigButton):
|
||||
"""Users should manage newlines with this class themselves"""
|
||||
|
||||
@@ -426,10 +422,6 @@ class NetworkSetupPageBase(Scroller):
|
||||
self._continue_button.set_text("install openpilot" if not custom_software else "choose software")
|
||||
self._continue_button.set_green(not custom_software)
|
||||
|
||||
def set_is_updater(self):
|
||||
self._continue_button.set_text("download\n& install")
|
||||
self._continue_button.set_green(False)
|
||||
|
||||
def _update_state(self):
|
||||
super()._update_state()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user