ThemeSwitcher: Load theme previews on demand - #1938
Open
robcodedev wants to merge 1 commit into
Open
Conversation
Startup loaded every preview PNG up front, so opening ThemeSwitcher on a card full of themes meant sitting through a "Loading previews... n/m" counter before you could do anything. Previews are now loaded when they are shown, keeping the last five around. themes_extract_previews.sh caches each archive's size and mtime, so an unchanged archive is skipped without running md5sum over the whole file. The sync after extraction is gone; previews are a cache and can be rebuilt. [ a == b ] isn't POSIX, so switch the comparisons to = and quote the read loops. BusyBox accepts ==, but the script no longer depends on that extension.
Copilot AI
added a commit
to Amiga500/Onion
that referenced
this pull request
Sep 9, 2026
…and previews, GameSwitcher favorites + crash fixes, fbmode framebuffer transitions Co-authored-by: Amiga500 <16525337+Amiga500@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Startup loaded every preview PNG up front, so opening ThemeSwitcher on a card
full of themes meant sitting through a "Loading previews... n/m" counter before
you could do anything. Previews are now loaded when they're shown, keeping the
last five around.
themes_extract_previews.shcaches each archive's size and mtime so anunchanged archive is skipped without running
md5sumover the whole file. Thesyncafter extraction is gone; previews are a regenerable cache.Also in the script
== is not POSIX and fails under dash; BusyBox accepts it as an extension, so
this was probably latent on device. Switched to
=and quoted the read loops.An empty extraction result is deliberately not cached, so a corrupt or
unreadable archive gets retried instead of being skipped until its size or
mtime changes.
Testing