From 65f99b89cce7af72e05ccb035bc2631e3594380c Mon Sep 17 00:00:00 2001 From: kdmukai Date: Sat, 21 Sep 2024 12:06:47 -0500 Subject: [PATCH] Revert Toast changes I instead submitted them as a PR to the main repo's `dev` branch: https://github.com/SeedSigner/seedsigner/pull/613 --- src/seedsigner/gui/toast.py | 4 ++-- tests/screenshot_generator/generator.py | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/seedsigner/gui/toast.py b/src/seedsigner/gui/toast.py index 41e499d6..2f4ff229 100644 --- a/src/seedsigner/gui/toast.py +++ b/src/seedsigner/gui/toast.py @@ -186,12 +186,12 @@ class BaseToastOverlayManagerThread(BaseThread): class RemoveSDCardToastManagerThread(BaseToastOverlayManagerThread): - def __init__(self, activation_delay=3, duration=1e6): + def __init__(self, activation_delay=3): # Note: activation_delay is configurable so the screenshot generator can get the # toast to immediately render. super().__init__( activation_delay=activation_delay, # seconds - duration=duration, # seconds ("forever") + duration=1e6, # seconds ("forever") ) diff --git a/tests/screenshot_generator/generator.py b/tests/screenshot_generator/generator.py index 0935c7a0..4e6c7ec8 100644 --- a/tests/screenshot_generator/generator.py +++ b/tests/screenshot_generator/generator.py @@ -132,7 +132,7 @@ def test_generate_screenshots(target_locale): MainMenuView, (MainMenuView, {}, 'MainMenuView_SDCardStateChangeToast_removed', SDCardStateChangeToastManagerThread(action=MicroSD.ACTION__REMOVED)), (MainMenuView, {}, 'MainMenuView_SDCardStateChangeToast_inserted', SDCardStateChangeToastManagerThread(action=MicroSD.ACTION__INSERTED)), - (MainMenuView, {}, 'MainMenuView_RemoveSDCardToast', RemoveSDCardToastManagerThread(activation_delay=0, duration=0)), + (MainMenuView, {}, 'MainMenuView_RemoveSDCardToast', RemoveSDCardToastManagerThread(activation_delay=0)), PowerOptionsView, RestartView, PowerOffView,