Skip to content

Popups and animations: blurred question cards tinted by the theme, and enter/exit animation fixes - #264

Open
Lenny4250gh wants to merge 13 commits into
anyplaynet:mainfrom
Lenny4250gh:main
Open

Lenny4250gh wants to merge 13 commits into
anyplaynet:mainfrom
Lenny4250gh:main

Conversation

@Lenny4250gh

@Lenny4250gh Lenny4250gh commented Oct 28, 2026 •

Copy link
Copy Markdown
Collaborator

What and why

The question cards (the cancel-unlock and quit popups) stood on a flat dim, and several panels broke or skipped their enter and exit animations. This pull request:

  1. puts the card on a blurred copy of the page behind it, tinted with the colour of the active theme;
  2. fixes the broken enter and exit animations of the full-screen panels, the settings rows, and the cancel-unlock and quit cards;
  3. makes the first opening of a panel (for example the "..." of a game) play its spawn animation instead of appearing at once.

Changes

Question cards: blurred page and theme colour

ui/pageblur.rs (new), screens/dialog.rs, ui/mod.rs

  • When a card opens, the window is captured once, shrunk to an eighth and blurred on the CPU (2 box passes, radius 3). The result is a small texture stretched over the screen.
  • While the card is open nothing is recomputed: a frame costs one textured quad. The texture is released when the card is gone (pageblur::release).
  • dialog::paint paints the flat scrim first and the blur on top. The scrim stays until the capture arrives (1-2 frames) and under High Contrast. The blur fades in over 0.15 s.
  • The card is a translucent pane over the blurred page (pageblur::paint_card). Until the page is captured, and under High Contrast, it is the previous glass panel.

ui/theme.rs, ui/background.rs

  • New Palette::card_wash(): the deep tone lifted 60% of the way to the middle one (blue on Cosmic, teal on Aurora, wine on Sunset, copper on Ember, petrol on Tide).
  • New theme::set_card_wash / theme::card_wash. The backdrop publishes the colour every frame; on Game Colors it uses the selected game's palette. pageblur::paint_card lays it at 0.38.
  • Daylight keeps its paper veil; High Contrast keeps the flat panel.

Animation fixes

ui/chrome.rs, fullscreen_panel

  • Glass: it fades its alpha in over the first half of the opening and out over the second half of the closing. Before, it was opaque from the first frame, so the page behind vanished in one frame and the panel seemed to cut in. The contents start fading in at v = 0.25, so the texts of two pages never overlap.
  • First opening: the openness uses animate_from_to(0.0 -> 1.0) instead of animate_to. A panel is drawn only while it is active, so its tracker is born on the frame it opens, and animate_to starts a new tracker at its target (no entrance). The first opening appeared at once; from the second on it animated. This affects every panel that uses fullscreen_panel; dialog.rs already did this.

screens/settings.rs

  • set_opacity is replaced by multiply_opacity. The rows' own fade replaced the panel's fade, so the rows stayed fully opaque while the page closed and vanished in the last frame.

app/panels.rs (cancel-unlock and quit cards)

  • The early return when cancel_ask is None is removed, so the card still goes through show and plays its exit. Before, the panel stayed in its closing state with nothing drawing it: it vanished at once, and on the next question it showed for one frame at full strength, left, and only then opened.
  • The quit card ("Close while installing?") had the same early return when quit_ask is None (after "Go back"), with the same symptoms. quit_ui now goes through show too; when the question is gone it uses QuitKind::Unlocking as a placeholder kind, since the card draws its exit from what it showed last and the kind only matters while it is open.

Docs

docs/DESIGN.md

  • 5.9.1 now says the card wears the theme's colour (Palette::card_wash, theme::set_card_wash, pageblur::paint_card at 0.38).
  • Gallery: home-cancel-ask with --theme=cosmic|aurora|sunset|ember|tide|daylight shows the card's tint on each theme.

Screenshots

Made with the gallery (made-up games, no game art), on the Cosmic theme:

home-quit home-quit-paused home-quit-removing

The other themes are reproduced with --gallery=home-cancel-ask --theme=<name>.

Checklist

  • cargo fmt --all -- --check, cargo clippy --workspace --all-targets -- -D warnings and cargo test --workspace pass.
  • A visible change follows docs/DESIGN.md, and the pull request shows the gallery screenshots of the changed scenes (--gallery=<scene> --screenshot=<file>).
  • Every new or changed text has English and Turkish strings. (No new or changed text.)
  • It works for every game. Nothing exists for one title; what is known per title is data.
  • No game data anywhere: no dumps, keys, firmware, saves, or logs and screenshots that show game memory or game art.

View with [code]smith Autofix with [code]smith
Need help on this PR? Tag @codesmith-bot with what you need.

@Lenny4250gh
Lenny4250gh requested a review from AlxcBTW October 28, 2026 18:04
@Lenny4250gh
Lenny4250gh deleted the branch anyplaynet:main October 28, 2026 22:12
@Lenny4250gh
Lenny4250gh deleted the main branch October 28, 2026 22:12
@Lenny4250gh
Lenny4250gh restored the main branch October 28, 2026 22:14
@Lenny4250gh Lenny4250gh reopened this Oct 28, 2026

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant