Compare commits
3
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
1099101f70
|
||
|
|
efaf585928 | ||
|
|
a78d7bd359 |
No files matched your search
@@ -35,8 +35,35 @@ numeric core and does not move; the heading is the full version — corrected 20
|
||||
|
||||
## [Unreleased]
|
||||
|
||||
### Added
|
||||
|
||||
- **Filters on Games and Compare** (owner request 2026-11-06, decision D85). Games: store, engine, state, installed and
|
||||
played, beside the search and sort, with *Clear filters*; the title counts what is shown of all. Compare: game, tier
|
||||
and frame generation over every session (it listed the newest 200), with a count; a ticked session stays listed.
|
||||
|
||||
### Changed
|
||||
|
||||
- **The list of games FrameLedger has been run with is current again** (`docs/LIST_GAME_TESTED.md`, decision D35's
|
||||
method): refreshed from a copy of the owner's database taken 2026-11-06 and reviewed by the owner — fifteen more
|
||||
games measured hooked, among them Phantom Blade Zero under the NVIDIA App's *Dynamic* mode, Hogwarts Legacy loading
|
||||
DLSS 5's runtime and the first two Xbox app games — and the sessions recorded without measurement or refused by the
|
||||
guard since 2026-09-27. The guide's Settings page says a language change stays on Settings; the closed §S30 notes the
|
||||
fifth Streamline id decoded (`docs/open-questions/closed-s.md`).
|
||||
- **The Compare page's layout** (the owner's screenshot): the selection bar beside the list instead of a window's width
|
||||
away, with *Clear selection*; columns sized to what they hold — *Tier* and *FPS* touched, and wide gaps split the rest —;
|
||||
the date sorts by when; the settings-changed column says so in words or shows a dash (it was blank); the result
|
||||
table's session labels sit over their columns.
|
||||
- **The selected page keeps its name in the left pane** (D86): WPF UI's pane animates the selected item's label away
|
||||
(Compare's, in the screenshot — every page's while selected); FrameLedger uses a copy of its template without that.
|
||||
- **Games opens at once from any page** (owner request 2026-11-06: switching to Games stalled 0.5–1.5 s). The window
|
||||
keeps the library page it built and shows it again on every later visit, reading the library again behind it; the
|
||||
library is read off the UI thread; the cards appear before the executables are checked — a USB drive that sleeps
|
||||
took a second or more to answer, and no card was shown until every one had — and each card gets its *Not installed*
|
||||
pill when its check answers; a read keeps every card that would look the same instead of rebuilding them all; the
|
||||
list view builds only the rows on screen (`spike-notes` §27).
|
||||
- **Changing the language keeps the page you are on** — Settings, after a change made there. The App remembered only
|
||||
the pages it opened from code, so the language changed on Settings came back on the last game page opened
|
||||
(`src/FrameLedger.App/Services/ShellHost.cs`).
|
||||
- **DLSS 5 is named where the game ran it** (owner decision D84, amending D64). The owner's Hogwarts Legacy, Neural
|
||||
Rendering on, loaded DLSS 5's runtime (`nvngx_dlssnr.dll` 310.9.16.0, from the game's folder) and the session could say
|
||||
only *DLSS 5 runtime loaded* — nothing measured whether it ran. The Overlay's Streamline hook now decodes DLSS 5's
|
||||
|
||||
+34
-4
@@ -1,6 +1,9 @@
|
||||
# 08 — UI
|
||||
|
||||
WPF + **WPF UI (Wpf.Ui, Fluent)**. Shell = `ui:FluentWindow` with custom `ui:TitleBar`, a thin classic **Menu bar** (file-level operations), and a left **`ui:NavigationView`** (`PaneDisplayMode="LeftFluent"`) as primary navigation. Light/Dark/System themes via `ApplicationThemeManager` + `SystemThemeWatcher`; Mica backdrop on Windows 11 with automatic solid fallback on Windows 10. All XAML follows `16_WPFUI_SYNTAX.md` — that doc is mandatory reading before writing views.
|
||||
WPF + **WPF UI (Wpf.Ui, Fluent)**. Shell = `ui:FluentWindow` with custom `ui:TitleBar`, a thin classic **Menu bar** (file-level operations), and a left **`ui:NavigationView`** (`PaneDisplayMode="LeftFluent"`) as primary navigation *(since beta.34, D86, its items use
|
||||
our copy of WPF UI 4.3.0's LeftFluent item template — `FlLeftFluentNavigationViewItemTemplate` in `Styles/FrameLedger.xaml` —
|
||||
whose only change is that the selected page keeps its label; WPF UI's animates it away, and the owner's screenshot of
|
||||
Compare showed the icon alone)*. Light/Dark/System themes via `ApplicationThemeManager` + `SystemThemeWatcher`; Mica backdrop on Windows 11 with automatic solid fallback on Windows 10. All XAML follows `16_WPFUI_SYNTAX.md` — that doc is mandatory reading before writing views.
|
||||
|
||||
## Shell
|
||||
|
||||
@@ -285,6 +288,13 @@ All screens are `Page`s registered with the navigation page provider and navigat
|
||||
|
||||
### Games (grid → detail)
|
||||
- `GridView`-style panel of cover cards (`ui:CardAction`): name, platform badge, engine badge, total playtime, last played, mini trend sparkline (avg Native FPS last 10 sessions). Sort/filter/`ui:AutoSuggestBox` search.
|
||||
> **The filters, beta.34 (owner request 2026-11-06, D85)** — specified here since P3 and never built: a row under the
|
||||
> search and sort with **Store**, **Engine** (the stores and engines the library holds, each list naming its
|
||||
> "everything" first; *Added by hand* for an entry with no store, *Engine not identified* for one with none),
|
||||
> **State** (the card's one state, as its pill says it), **Installed** and **Played**, and *Clear filters*. While a filter
|
||||
> or the search narrows the list the title counts what is shown of all (*Games · 12 of 65*). Kept while the App runs —
|
||||
> the page is the window's (`WindowPageCache`) — and not saved. Tests:
|
||||
> `GamesViewModelTests.TheFiltersNarrowTheLibraryAndTheHeaderCountsWhatIsShown`.
|
||||
> **The library, beta.11 (owner requests 2026-10-03).** *The empty band on the right:* the cards were 300 px in a plain
|
||||
> `WrapPanel`, so at ~1350 px three fitted and a card's width was left unused; the grid is now
|
||||
> `Controls.UniformWrapPanel` — as many columns as fit at 300 px or wider, every card an equal share of the width, each row
|
||||
@@ -305,7 +315,14 @@ All screens are `Page`s registered with the navigation page provider and navigat
|
||||
> message at once in its one snackbar, so only the last name stayed on screen. And only the newest read of the library is
|
||||
> shown: reads overlap — a session that ends, an import, a removal — and the one that started first could finish last,
|
||||
> its executable checks waiting on a slow drive, and put back a removed game's card (`GamesViewModel.LoadAsync`,
|
||||
> `GamesViewModelTests.AnOlderReadThatFinishesLastIsNotShownOverANewerOne`)*). **The page reloads by itself** while it is on screen when a session ends (`SessionCompleted`) or an
|
||||
> `GamesViewModelTests.AnOlderReadThatFinishesLastIsNotShownOverANewerOne`)*). *(beta.34, owner request 2026-11-06 —
|
||||
> "switching to Games stalls 0.5–1.5 s", `spike-notes` §27: the window keeps the page it built and shows it again on
|
||||
> every later visit, reading the library again behind it; the library is read on the thread pool; the cards appear
|
||||
> before any executable is checked — 39 of the owner's 41 Steam games are on a USB drive that sleeps — and each card
|
||||
> gets its *Not installed* pill when its check answers; a read keeps every card that would look the same; the list
|
||||
> view is bounded (`MaxHeight` 640) so it builds the rows on screen. `GamesViewModelTests`
|
||||
> `.TheCardsComeBeforeTheExecutableChecksAndThePillAfter`, `.APageShownAgainReadsTheLibraryAndKeepsTheCardsThatLookTheSame`,
|
||||
> `WindowPageCacheTests`.)* **The page reloads by itself** while it is on screen when a session ends (`SessionCompleted`) or an
|
||||
> import adds games (`LibraryChanges` — navigating to the page already on screen does nothing in WPF UI 4.3.0, so an
|
||||
> import from the menu never showed until the page was left). **Import** (FR-1.2): the games already in the library — at
|
||||
> this path or under another drive letter — are hidden by default (*Show the N games already in the library* brings them
|
||||
@@ -625,7 +642,10 @@ Stat cards (Avg uses `FpsReadout`, Median, 1% Low, 0.1% Low, Min/Max, σ, stutte
|
||||
> frame-generation state)*, *DLSS 3 (library 3.7.10)* — else *DLSS*; then each DLSS library with its version and where
|
||||
> it was loaded from (*Super Resolution 310.5.0, from the graphics driver, preset L (2nd-gen transformer model)*), then
|
||||
> *DLSS 5 runtime loaded* when it was. The game page's *Last session measured* repeats the label; the CSV export gains
|
||||
> `# dlss:`. `DlssTextTests`.
|
||||
> `# dlss:`. `DlssTextTests`. *(beta.34: two more rows — the NVIDIA App's Dynamic frame generation the driver reports
|
||||
> applied is *DLSS 4.5 (Dynamic multi frame generation, set in the NVIDIA App)* (D83), and *DLSS 5 (neural rendering on
|
||||
> N % of rendered frames)* heads the line where the game was seen running it, its library listed like the others, *runtime
|
||||
> loaded, not seen running* where the Overlay looked and saw none (D84) — `05_DETECTION` §DLSS generation.)*
|
||||
|
||||
> **beta.27: one window per session, and no DLSS line that says only *DLSS*.** Opening a session whose summary window is
|
||||
> open — from a Sessions tab, a notification, the game page — brings that window forward, restored if minimised, rather
|
||||
@@ -773,10 +793,20 @@ Stat cards (Avg uses `FpsReadout`, Median, 1% Low, 0.1% Low, Min/Max, σ, stutte
|
||||
|
||||
### Compare
|
||||
Session picker (2–5, cross-game allowed) → overlaid percentile curves + stat table with best-value highlighting; FG columns always show Native and Displayed separately. Export PNG.
|
||||
> **beta.34 (owner request 2026-11-06, with a screenshot; D85).** The list holds **every session** — it was the newest
|
||||
> 200, read on the UI thread with one game lookup each; now one read of the names, on the thread pool — and filters by
|
||||
> **Game**, **Tier** and **Frame generation** (with / without; a session that measured none is neither), with a count
|
||||
> (*6 of 131 sessions*); a ticked session stays listed whatever the filters say. The selection bar — *Pick 2 to 5
|
||||
> sessions*, the count, *Clear selection*, *Compare* — sits above the list on the left: it was a window's width away. The
|
||||
> columns are sized to what they hold with one filler column after them (three star columns spread a wide window into
|
||||
> gaps, and the Tier column was exactly its header's width, so *Tier* and *FPS* touched); the date sorts by when; the
|
||||
> settings-changed cell says *Changed mid-session* beside its icon, or a dash (it was blank). The result table's session
|
||||
> labels sit over their columns: the header row has the metric column's 140 px first, as every row does. Tests:
|
||||
> `CompareViewModelTests.TheFiltersNarrowTheListAndATickedSessionStaysOnIt`, the page in `PagesLoadTests`' surfaces.
|
||||
|
||||
**Mixed-tier guard (FR-6.2):** selecting sessions from different capture tiers shows a blocking `ContentDialog` explaining that they measured different things; proceeding stamps the chart with a tier legend and greys out metrics unavailable in the lower tier. Sessions with `settings_changed_midsession` carry a warning icon and are excluded from trend lines by default.
|
||||
|
||||
> **Built 2026-09-14 (P3 PR-7).** `CompareViewModel` over the last 200 sessions across games: a `DataGrid`
|
||||
> **Built 2026-09-14 (P3 PR-7).** `CompareViewModel` over ~~the last 200 sessions~~ every session *(since beta.34)* across games: a `DataGrid`
|
||||
> picker with a checkbox column (Compare enabled at 2–5), the FR-6.4 warning icon per row; **Compare** asks
|
||||
> `IMixedTierPrompt` (a `ContentDialog`, default button Cancel) when the selection mixes tiers and compares
|
||||
> nothing on a decline; a comparison that proceeds carries `Compare_Mixed_Legend` as the plot's title and an
|
||||
|
||||
@@ -17,6 +17,10 @@ Languages: **en** (neutral/default) · **vi** · **ja**. Same `.resx` pattern as
|
||||
- One `Strings.resx` (+ `Strings.vi.resx`, `Strings.ja.resx`) per assembly that has user-visible text (`App`, `Shared` ~~for error codes~~ for the safety family, the `Safety_*` keys — corrected 2026-10-04). Access through a generated strongly-typed class; **no string literals in XAML/C# for user-visible text** (analyzer TODO: Meziantou MA0011/manual review in PR checklist). **As built (P3 PR-2, 2026-09-13):** the class is `Strings.Designer.cs`, written by `tools/resx-gen.ps1 -Resx <file>` and **committed** — not the SDK's `ResXFileCodeGenerator`, which the SDK-style WPF project does not run — with `Culture`, `ResourceManager`, `Keys`, and one property per key; the audit below fails when it is stale. The first family is `src/FrameLedger.App/Strings.resx` (65 keys); `Shared`'s arrives with PR-4's `Safety_*` text, because an empty family is what the audit refuses.
|
||||
- XAML binding via `{x:Static res:Strings.Key}` ~~plus a `LocalizeExtension` for the few dynamic cases~~ *(corrected 2026-10-04: no `LocalizeExtension` exists; text that varies is composed in the view model from `Strings.*`)*.
|
||||
- **Runtime switching:** setting change → set `CultureInfo.CurrentUICulture` + `Thread` defaults → re-create the main window shell (cheap; state preserved via VM). Persist in `settings`.
|
||||
**The new window opens on the page that was on screen** *(beta.34, owner request 2026-11-06)* — Settings, after a
|
||||
change made there. `ShellHost` remembered only the pages opened from code (`PageNavigator`), never a click in the
|
||||
pane, so a language changed on Settings brought back the last game page opened; it now notes every page the live
|
||||
window's NavigationView shows (`ShellHost.NoteShown`).
|
||||
**Two kinds of text did not follow, until beta.15:** a list of choices built once in a static (Settings' themes and update
|
||||
channels, the Logs page's two lists, the Games page's sort order — `x:Static` read the list built in the language the
|
||||
App started in), and the singletons that outlive the rebuilt window (the tray's menu, the title bar's Agent pill and the
|
||||
|
||||
@@ -115,6 +115,14 @@ Code-behind wires services once: `navigationService.SetNavigationControl(RootNav
|
||||
- Navigate **only** via `INavigationService.Navigate(typeof(SomePage))` — never manipulate `Frame` directly, never `new` a Page.
|
||||
- Pages implement `INavigableView<TViewModel>` with `ViewModel` injected via constructor DI; `DataContext = this` in the page constructor (WPF UI template idiom) so bindings read `ViewModel.*`.
|
||||
- Page state: pages are Transient; anything that must survive navigation lives in the ViewModel-backing services/DB, not the Page.
|
||||
**Except the library, since beta.34** (owner request 2026-11-06, "Games stalls 0.5–1.5 s"; `spike-notes` §27): the window
|
||||
keeps the `GamesPage` it built — `Services.WindowPageCache`, the window's own `INavigationViewPageProvider`, set after
|
||||
`INavigationService.SetNavigationControl` (which hands the NavigationView the container's provider) — and its view model
|
||||
reads the library again each time the page is shown (`GamesViewModel.Attach`). Still Transient in the container; one
|
||||
instance per window, so a language change's new window builds its own in the new language. **Not**
|
||||
`NavigationViewItem.NavigationCacheMode`: WPF UI 4.3.0 reads it only when the NavigationView has neither a service
|
||||
provider nor a page provider (`NavigationView.Navigation.cs`, `GetNavigationItemInstance`), and this App sets one — the
|
||||
attribute would have changed nothing.
|
||||
|
||||
## Control mapping (always prefer these)
|
||||
|
||||
|
||||
+4
-1
@@ -363,7 +363,8 @@ an alpha's release has to find — #350's lookup, by the name the pack lists. It
|
||||
`Art_Source_Xbox`, `Import_NothingFound`, `FirstRun_Import_Body`, `Settings_GameArt_Body`, `Play_Xbox_Format`,
|
||||
`Play_Xbox_NotStarted_Format`, `Play_PackagedGame_Format`, `Play_ToolTip_Store`, `Play_ToolTip_Direct`,
|
||||
`Settings_PlayMode_Body`, `Guard_TargetAppContainer`, `Guard_TargetMitigation`. Then
|
||||
`docs/LIST_GAME_TESTED.md` gains the Xbox titles from a ledger copy (D35), approved before the commit.
|
||||
`docs/LIST_GAME_TESTED.md` gains the Xbox titles from a ledger copy (D35), approved before the commit. *(2026-11-06,
|
||||
beta.34: done — inKONBINI and Valor Mortis, with the refresh the owner approved with the plan.)*
|
||||
29. **0.1.0-alpha.2 on real hardware** (D73, D82). (a) **The update from alpha.1**: Help ▸ Check for updates offers
|
||||
alpha.2 — the first update an alpha's updater has found — and *Restart to update* installs it; say whether it
|
||||
downloaded the delta or the whole package. (b) The terms window shows the Privacy Policy 2.13 and the Alpha notice
|
||||
@@ -468,6 +469,8 @@ Where each owner decision is recorded — the file and its section, and a label
|
||||
| D82 | [`HANDOFF.md`](HANDOFF.md) §START HERE | alpha.2 right after beta.33; on RC3 unless the train reaches it after .NET 11 ships (then SDK 11.0.100, packages 11.0.0) |
|
||||
| D83 | [`05_DETECTION.md`](05_DETECTION.md) §DLSS generation | the NVIDIA App's Dynamic frame generation, reported applied by the driver in a session that counted DLSS Frame Generation, is DLSS 4.5 (amends D64) |
|
||||
| D84 | [`05_DETECTION.md`](05_DETECTION.md) §DLSS generation | DLSS 5 heads the DLSS line where its neural rendering was measured running (`kFeatureDLSS_NR`, `dlss_nr_pct`); loaded only reads "runtime loaded" (amends D64) |
|
||||
| D85 | [`08_UI.md`](08_UI.md) §Games, §Compare | filters: Games — store, engine, state, installed, played; Compare — game, tier, frame generation (no period); Compare lists every session |
|
||||
| D86 | [`08_UI.md`](08_UI.md) (the shell) | the left pane's selected item keeps its label: our copy of WPF UI 4.3.0's LeftFluent item template |
|
||||
|
||||
---
|
||||
|
||||
|
||||
+46
-16
@@ -1,43 +1,47 @@
|
||||
# Games FrameLedger has been run with
|
||||
|
||||
*As of 2026-09-27 (0.1.0-beta.10). Built from a copy of the developer's own FrameLedger database and the repository's
|
||||
*As of 2026-11-06 (0.1.0-beta.34). Built from a copy of the developer's own FrameLedger database and the repository's
|
||||
measurement notes, and reviewed by the project's owner before it was published. It lists what happened on one machine;
|
||||
it promises nothing about any other.*
|
||||
|
||||
*(Not re-read for 0.1.0-beta.11 or 0.1.0-beta.12 — noted 2026-10-04. Refreshing it needs a new copy of the database and
|
||||
the owner's review; sessions since 2026-09-27, and the game-memory figures beta.12 adds, are not here.)*
|
||||
*~~(Not re-read for 0.1.0-beta.11 or 0.1.0-beta.12 — noted 2026-10-04. Refreshing it needs a new copy of the database and
|
||||
the owner's review; sessions since 2026-09-27, and the game-memory figures beta.12 adds, are not here.)~~ Refreshed
|
||||
2026-11-06 from a copy of the database taken that day, and reviewed by the owner with the plan of 0.1.0-beta.34: the
|
||||
sessions since 2026-09-27 are below, with the graphics memory a game used where it adds something.*
|
||||
|
||||
**The machine.** Every row below was run on one PC: an NVIDIA GeForce RTX 5080 (the only graphics card), an Intel Core
|
||||
i7-14700KF, 32 GB of DDR5, Windows 11 (Insider builds 26300 → 29648) and a 2560×1440, 240 Hz monitor. **No AMD or Intel
|
||||
i7-14700KF, 32 GB of DDR5, Windows 11 (Insider builds 26300 → 29648) and a 2560×1440, 240 Hz monitor; the graphics
|
||||
driver went from 32.0.16.1714 to 32.0.16.2114 over the sessions in the database. **No AMD or Intel
|
||||
graphics card and no second machine has been tested**, and ~~**no real Vulkan or OpenGL game has been measured** — every
|
||||
measurement below is Direct3D 11 or 12~~ **one real Vulkan game has been measured (Everhex Demo, 2026-10-13) and no
|
||||
OpenGL game** — every other measurement below is Direct3D 11 or 12 *(corrected 2026-10-14)*. What the tiers mean and what FrameLedger cannot do: [LIMITATIONS.md](../LIMITATIONS.md).
|
||||
|
||||
**Two periods.** From 2026-08-03 to 2026-09-06 the games were measured with the developer's capture tool, one run at a
|
||||
time against the game's own settings menu (reports in [spike-notes.md](spike-notes.md)). From 2026-09-16 the shipped
|
||||
app and agent recorded them as a user would; the database holds the sessions from 2026-09-22 on — earlier ones went
|
||||
with the 2026-09-16 recovery and with library entries removed since.
|
||||
app and agent recorded them as a user would; ~~the database holds the sessions from 2026-09-22 on~~ the copy of
|
||||
2026-11-06 holds the sessions from 2026-10-04 on — earlier ones went with the 2026-09-16 recovery and with library
|
||||
entries and sessions removed since; a row citing the database before 2026-10-04 was read from the copy of 2026-09-27.
|
||||
|
||||
## Measured — hooked (Tier 1)
|
||||
|
||||
| Game | Engine | API | What was measured | When | Evidence |
|
||||
|---|---|---|---|---|---|
|
||||
| Cyberpunk 2077 | — | D3D12 | DLSS Balanced 1485×835 → 2560×1440, exact against its settings file; DLSS Frame Generation off ×1.00, ×3 (61.4 → 183.5 FPS), ×4 (58.7 → 234.1); FSR 3 + FSR frame generation ×2 (74.3 → 148.6); ray tracing *Yes* with path tracing on and *No* with it off, as set | 2026-08-15 → 09-05, about 25 runs | [spike-notes §8, §9, §11](spike-notes.md) |
|
||||
| Cyberpunk 2077 | — | D3D12 | DLSS Balanced 1485×835 → 2560×1440, exact against its settings file; DLSS Frame Generation off ×1.00, ×3 (61.4 → 183.5 FPS), ×4 (58.7 → 234.1); FSR 3 + FSR frame generation ×2 (74.3 → 148.6); ray tracing *Yes* with path tracing on and *No* with it off, as set; on 2026-10-20, ×2, ×3 and ×4 chosen in the game's menu within one session read as separate states, ×4.0 at 63.8 → 255.3 FPS, with ray tracing and Ray Reconstruction *Yes* | 2026-08-15 → 10-20, about 26 runs | [spike-notes §8, §9, §11, §23](spike-notes.md), database |
|
||||
| Dying Light: The Beast | — | D3D12 | DLSS Frame Generation ×4: Native 70.5 → Displayed 282.1 FPS, counted through DXGI; FSR + FSR frame generation ×2 (70.5 → 140.9); ray tracing *Yes* | 2026-09-04 → 09-06 | [spike-notes §9](spike-notes.md), [03_METRICS §Frame Generation](03_METRICS.md) |
|
||||
| Hell Is Us | Unreal Engine 5.5.4 | D3D12 | DLSS Frame Generation ×4 (76.5 → 306.2); DLSS shown as *driver-reported* (it bypasses Streamline); FSR + FSR frame generation ×2 (85.7 → 171.4); XeSS frame generation shown as Presented FPS only; ray tracing *No* | 2026-09-03 → 09-16 | [spike-notes §8, §9](spike-notes.md) |
|
||||
| Black Myth: Wukong | Unreal Engine 5.0.0 | D3D12 | DLSS Frame Generation ×4 (55.4 → 221.5); ray tracing *Yes* (16.2 % of frames in the app's session); a session that changed state showed its steady state (×4.1) instead of an average | 2026-08-20 → 09-16 | [spike-notes §9, §14](spike-notes.md) |
|
||||
| Clair Obscur: Expedition 33 | Unreal Engine 5.4.4 | D3D12 | DLSS + Frame Generation ×4 (54.9 → 218.4) and ×2 (76.0 → 149.8); frame generation off read *none*, with DXGI agreeing; ray tracing *No* | 2026-09-04 → 09-06 | [spike-notes §9](spike-notes.md) |
|
||||
| Clair Obscur: Expedition 33 | Unreal Engine 5.4.4 | D3D12 | DLSS + Frame Generation ×4 (54.9 → 218.4) and ×2 (76.0 → 149.8); frame generation off read *none*, with DXGI agreeing; ray tracing *No*; the NVIDIA App's *Fixed ×6* read ×6.0 (81.8 → 490.9) on 2026-10-20 | 2026-09-04 → 10-20 | [spike-notes §9, §23](spike-notes.md), database |
|
||||
| Rune Factory: Guardians of Azuma | Unreal Engine (version not in the executable) | D3D12 | DLSS Frame Generation ×4 (128.9 → 513.0); FSR frame generation compiled into the game counted ×2 but not named; ray tracing *No* (the game has none) | 2026-08-20 → 09-06 | [spike-notes §9](spike-notes.md) |
|
||||
| Kingdom Come: Deliverance II | — | D3D12 | FSR (3.1 or 4) at 1505×847 → 2560×1440; frame generation *none* (the game ships none); ray tracing *No* | 2026-09-04 | [spike-notes §9](spike-notes.md) |
|
||||
| Lies of P | Unreal Engine 4.27.2 | D3D12 | FSR 3 at 1506×848 → 2560×1440 with FSR frame generation ×2.04 (57.1 → 116.4) in the app; frame generation off read *none*; DLSS shown as *driver-reported*; ray tracing *No* | 2026-08-03 → 09-16 | [spike-notes §7, §9, §14](spike-notes.md) |
|
||||
| Lies of P | Unreal Engine 4.27.2 | D3D12 | FSR 3 at 1506×848 → 2560×1440 with FSR frame generation ×2.04 (57.1 → 116.4) in the app; frame generation off read *none*; DLSS shown as *driver-reported*; ray tracing *No*; on 2026-10-19 and 10-20, FSR 3 at 1707×961 and at 1280×720 → 2560×1440 with FSR frame generation ×2.0 (54.6 → 109.6, 57.6 → 116.7) and no FSR quality mode — the game never asked for one while the hook was in | 2026-08-03 → 10-20 | [spike-notes §7, §9, §14, §22, §23](spike-notes.md), database |
|
||||
| Onimusha: Way of the Sword (demo) | RE Engine | D3D12 | DLSS + DLSS Frame Generation: ×3.67 and ×3.93 with the capture tool, ×4.00 in the app's steady state (60 → 240 FPS), ×3.0 (60 → 180) in the app on 2026-09-22; ray tracing *Yes* | 2026-09-05 → 09-22 | [spike-notes §9, §14](spike-notes.md), database |
|
||||
| Cronos: The New Dawn (demo) | Unreal Engine (version not in the executable) | D3D12 | DLSS with frame generation off (105 FPS, *none*); on ×2 (86.8 → 172.7), DLSS Frame Generation named; ray tracing *Yes* | 2026-09-06 → 09-16 | [spike-notes §9, §14](spike-notes.md) |
|
||||
| Alan Wake 2 | — | D3D12 | Path tracing Ultra with DLSS and Ray Reconstruction: ray tracing *Yes* (96.8 % of frames), frame generation read ×1.00 (the game did not apply the setting that run). On 2026-09-04: DLSS with ray tracing *Yes* (99 % of frames), 92.5 FPS, frame generation *none* by count; then ray tracing off (*No*), DLSS, Presented 114.5 FPS. The quality preset was never read | 2026-08-04 → 09-04 | [spike-notes §8](spike-notes.md), run reports |
|
||||
| SILENT HILL 2 | Unreal Engine 5.1 | D3D12 | DLSS Frame Generation identified, frames not counted (Presented 78 FPS); DLSS *driver-reported*; ray tracing *Yes* | 2026-09-25 | database |
|
||||
| DARK SOULS III | FromSoftware | D3D11 | Presented 59.8 FPS; no upscaler, frame generation or ray tracing loaded | 2026-09-03 | [spike-notes §9](spike-notes.md) |
|
||||
| Sekiro: Shadows Die Twice | FromSoftware | D3D11 | Presented 60 FPS (the game's cap), two sessions of 15 min and 2 h 18 min | 2026-09-26 | database |
|
||||
| SILENT HILL 2 | Unreal Engine 5.1 | D3D12 | DLSS Frame Generation identified, frames not counted (Presented 78 FPS) on 2026-09-25; then under the NVIDIA App's *Fixed ×6* ×6.0 (53.3 → 320.0) and under its *Dynamic, up to ×6* states ×2.0, ×3.0 and ×6.1; DLSS *driver-reported*; ray tracing *Yes* | 2026-09-25 → 10-20 | database, [spike-notes §22, §23](spike-notes.md) |
|
||||
| DARK SOULS III | FromSoftware | D3D11 | Presented 59.8 FPS; no upscaler, frame generation or ray tracing loaded; then 34 sessions at the game's 60 FPS cap, the longest 6 h 12 min, four of them ended by the game crashing | 2026-09-03 → 10-25 | [spike-notes §9](spike-notes.md), database |
|
||||
| Sekiro: Shadows Die Twice | FromSoftware | D3D11 | Presented 60 FPS (the game's cap): two sessions of 15 min and 2 h 18 min, then three more of up to 1 h 6 min | 2026-09-26 → 10-29 | database |
|
||||
| Yu-Gi-Oh! Master Duel | Unity 6000.0 | D3D11 | Presented 239 FPS across six sessions (up to 5 h 25 min) | 2026-09-22 → 09-25 | database |
|
||||
| GIRLS' FRONTLINE 2: EXILIUM | Unity 2019.4 | D3D11 | Presented 53–101 FPS; the last three sessions under the user-mode anti-cheat exception (NetEase Yidun), one of them 3 h 9 min, all ended normally | 2026-09-21 → 09-27 | database, [HANDOFF](HANDOFF.md) |
|
||||
| GIRLS' FRONTLINE 2: EXILIUM | Unity 2019.4 | D3D11 | Presented 53–101 FPS; the last three sessions under the user-mode anti-cheat exception (NetEase Yidun), one of them 3 h 9 min, all ended normally; ten more under the exception, 28–72 FPS, the longest 2 h 9 min, all ended normally | 2026-09-21 → 10-20 | database, [HANDOFF](HANDOFF.md) |
|
||||
| Aniimo | Unity 2022.3 | D3D12 | DLSS at 1707×960 → 2560×1440, frame generation *none* (×1.00, 205 FPS), ray tracing *No* — then blocked (below) | 2026-09-22 | database |
|
||||
| AbyssMemory | Unreal Engine 4.26.1 | D3D11 | Presented 55 FPS, one short session | 2026-09-22 | database |
|
||||
| Umamusume: Pretty Derby | Unity 2022.3 | D3D11 | Presented 37 FPS, one session | 2026-09-27 | database |
|
||||
@@ -45,6 +49,21 @@ with the 2026-09-16 recovery and with library entries removed since.
|
||||
| Flower in Us | RPG Maker MV/MZ (NW.js) | D3D11 | Presented 59.8 FPS over three swap chains, after two refusals that found the game's browser process ambiguous (fixed) | 2026-09-03 → 09-04 | [spike-notes §9](spike-notes.md) |
|
||||
| UMIGARI | Unreal Engine 5.5.4 | D3D12 | Presented 95–97 FPS, frame generation *none*, ray tracing *No* | 2026-09-05 → 09-06 | run reports only |
|
||||
| Everhex Demo | — | Vulkan | Presented 239.7 FPS (1 % low 213.5), 14,955 frames in 69 s, through FrameLedger's Vulkan layer — the first real Vulkan game measured; started by Play set to *Start directly* | 2026-10-13 | database *(row added 2026-10-14 from a copy of the database)* |
|
||||
| The Witcher 3: Wild Hunt — Remastered | — | D3D12 | DLSS 1707×960 → 2560×1440 with DLSS Frame Generation ×2.0 (118.8 → 237.4 FPS); ray tracing and Ray Reconstruction *Yes*; under the NVIDIA App's *Fixed ×6* it still presented ×2.0 — the setting is not the frames | 2026-10-04 → 10-20 | database, [spike-notes §23](spike-notes.md) |
|
||||
| Phantom Blade Zero | Unreal Engine (version not in the executable) | D3D12 | DLSS *driver-reported*; DLSS Frame Generation under the NVIDIA App's *Dynamic* mode: up to ×6 held ×4.0 (59.5 → 235.6 FPS) and ×5.2 (44.3 → 231.2), up to ×3 held ×3.0 (58–76 → 175–227) for 75–94 % of each session longer than an hour; ray tracing *Yes*; thirteen sessions, the longest 6 h 29 min (5.26 million frames); up to 9.6 GB of graphics memory | 2026-11-01 → 11-05 | database, [spike-notes §26](spike-notes.md) |
|
||||
| Hogwarts Legacy | Unreal Engine (version not in the executable) | D3D12 | With the game's *Neural Rendering* on, DLSS 5's runtime (`nvngx_dlssnr.dll` 310.9.16.0) loaded from the game's folder — the first game seen loading it; DLSS *driver-reported*; DLSS Frame Generation not counted (non-uniform, ×1.97 overall), Presented 140.2 FPS; ray tracing *Yes*, Ray Reconstruction *No* | 2026-11-06 | database, [spike-notes §26](spike-notes.md) |
|
||||
| Valor Mortis (Xbox app) | Unreal Engine | D3D12 | DLSS Frame Generation ×6.0 (39.9 → 239.2 FPS), DLSS *driver-reported*, ray tracing *No*; recorded in attach mode | 2026-11-04 | database |
|
||||
| inKONBINI (Xbox app) | Unity 6000.0 | D3D11 | Presented 205.9 FPS, one short session | 2026-11-03 | database |
|
||||
| DARK SOULS II: Scholar of the First Sin | FromSoftware | D3D11 | The game's 60 FPS cap, nine sessions up to 5 h 29 min; one was unhooked by the safety check and recorded on | 2026-10-09 → 10-12 | database |
|
||||
| Mithril | Unreal Engine (version not in the executable) | D3D12 | Presented 91.5–119.4 FPS, ray tracing *Yes*, four sessions up to 3 h 4 min | 2026-10-12 → 10-16 | database |
|
||||
| KEEP IT ON HER | Unreal Engine 5.8 | D3D12 | Presented 59.5–108.8 FPS, ray tracing *Yes* | 2026-10-12 → 10-13 | database |
|
||||
| WALTO | Unity 6000.3 | D3D12 | Presented 212.5 FPS over 2 h 41 min (2,057,022 frames) | 2026-10-08 | database |
|
||||
| White Mask Mansion | Unity 6000.1 | D3D12 | Presented 286–309 FPS, five sessions | 2026-10-27 | database |
|
||||
| LIMINAL: Within Demo | Unity 2022.3 | D3D11 | Presented 222.5–228.6 FPS | 2026-10-12 | database |
|
||||
| Sleepytime Village | Unity 2021.3 | D3D11 | Presented 906–1,440 FPS (the game sets no cap) | 2026-10-25 → 10-26 | database |
|
||||
| Scarlet Wolf | Unity 2021.3 | D3D11 | Presented 128.5 FPS | 2026-10-15 | database |
|
||||
| March Out! Playtest | Unity 2022.3 | D3D11 | Presented 118.2 FPS | 2026-10-08 | database |
|
||||
| A Space for the Unbound – Prologue (GOG) | Unity 2019.4 | D3D11 | Presented 61.0 FPS, started by FrameLedger | 2026-10-20 | database |
|
||||
|
||||
## Recorded without measurement (Tier 2)
|
||||
|
||||
@@ -52,8 +71,14 @@ with the 2026-09-16 recovery and with library entries removed since.
|
||||
|---|---|---|---|
|
||||
| HELLO, HELLO WORLD! | A 32-bit game (RPG Maker MV): refused by the guard once, and two sessions with hooking switched off — each recorded with its duration and sensors. *Its itch.io download puts malware in front of the game — do not run it (noted 2026-10-13, [spike-notes §20](spike-notes.md))* | 2026-09-23 | database |
|
||||
| Umamusume: Pretty Derby | Three sessions played with hooking switched off for the game | 2026-09-27 | database |
|
||||
| Sekiro: Shadows Die Twice | One session played with hooking switched off | 2026-09-25 | database |
|
||||
| Sekiro: Shadows Die Twice | Two sessions played with hooking switched off | 2026-09-25, 10-07 | database |
|
||||
| GIRLS' FRONTLINE 2: EXILIUM | One session whose process Windows would not let FrameLedger open, and two recovered after the agent itself stopped mid-session (*interrupted*) | 2026-09-22 → 09-23 | database |
|
||||
| Bound Between Desks | Two sessions with hooking switched off (a Ren'Py 8.5 game) | 2026-10-15 → 10-20 | database |
|
||||
| Phantom Blade Zero | Three sessions after a game update changed its executable on 2026-11-04, until hooking was consented to again on 11-05; one refused because a module list came back incomplete | 2026-11-04 → 11-05 | database |
|
||||
| The Witcher 3: Wild Hunt — Remastered | Three sessions before hooking was consented to | 2026-10-13 → 10-20 | database |
|
||||
| Mithril | Two sessions before hooking was consented to | 2026-10-16 | database |
|
||||
| Hogwarts Legacy | One session with hooking switched off; Windows logged a crash of the game | 2026-11-06 | database |
|
||||
| Valor Mortis, WALTO, Scarlet Wolf, Lies of P, A Space for the Unbound – Prologue | One session each with hooking switched off | 2026-10-08 → 11-04 | database |
|
||||
|
||||
## Refused by the anti-cheat guard
|
||||
|
||||
@@ -64,7 +89,10 @@ with the 2026-09-16 recovery and with library entries removed since.
|
||||
| Aniimo | NetEase Yidun with a kernel driver (`NEPKernel.sys`) in the game's folder — never eligible for an exception | 2026-09-25 | [19_SAFETY](19_SAFETY_AND_ANTICHEAT.md) |
|
||||
| Goose Goose Duck | Easy Anti-Cheat's service running, and its folder | 2026-08-04 | [spike-notes §13](spike-notes.md) |
|
||||
| Neverness To Everness | Anti-Cheat Expert's kernel driver in the game's folder | 2026-08-04 | [spike-notes §13](spike-notes.md) |
|
||||
| Wuthering Waves | Anti-Cheat Expert, kept beside the game's executable four folder levels in, where the check did not look before beta.21: a session with hooking on was injected and unhooked 37 seconds later, when the 30-second re-check met ACE's driver (`ACE-BASE.sys`); nothing was measured. Since beta.21 its folder and its Steam id refuse it before any injection *(row added 2026-10-13 from the agent's log)* | 2026-10-12 | [spike-notes §19](spike-notes.md) |
|
||||
| Wuthering Waves | Anti-Cheat Expert, kept beside the game's executable four folder levels in, where the check did not look before beta.21: a session with hooking on was injected and unhooked 37 seconds later, when the 30-second re-check met ACE's driver (`ACE-BASE.sys`); nothing was measured. Since beta.21 its folder and its Steam id refuse it before any injection *(row added 2026-10-13 from the agent's log)*; two sessions recorded without measurement on 2026-10-31 | 2026-10-12 → 10-31 | [spike-notes §19](spike-notes.md), database |
|
||||
| Arknights: Endfield | Anti-Cheat Expert's folder (`AntiCheatExpert`) beside the game; one session recorded without measurement | 2026-10-31 | database |
|
||||
| Stella Sora | Anti-Cheat Expert's folder (`AntiCheatExpert`); three sessions recorded without measurement | 2026-10-30 → 10-31 | database |
|
||||
| Umamusume: Pretty Derby | CrackProof, on FrameLedger's title list since beta.11 (Steam 3224770) — measured before the list named it (above) | 2026-10-03 | [19_SAFETY](19_SAFETY_AND_ANTICHEAT.md) |
|
||||
| Counter-Strike 2 | Valve Anti-Cheat — refused by FrameLedger's title list since beta.8. On 2026-08-04 the checks alone allowed it (VAC is invisible to them); nothing was injected | 2026-08-04, beta.8 | [spike-notes §13](spike-notes.md), [19_SAFETY](19_SAFETY_AND_ANTICHEAT.md) |
|
||||
|
||||
Also refused before any injection: **Deadly Heart Gambit** — a 32-bit game (2026-08-03).
|
||||
@@ -74,4 +102,6 @@ Also refused before any injection: **Deadly Heart Gambit** — a 32-bit game (20
|
||||
The Unreal Engine version (beta.10) was checked against ten installed Unreal games without running them: Hell Is Us
|
||||
5.5.4, Black Myth: Wukong 5.0.0, Clair Obscur: Expedition 33 5.4.4, Lies of P 4.27.2, SILENT HILL 2 5.1, UMIGARI 5.5.4,
|
||||
AbyssMemory 4.26.1, **Martha Is Dead 4.27.0**; Cronos (demo) and Rune Factory name no version in their executables and
|
||||
read *not found*. ([spike-notes §15](spike-notes.md), [05_DETECTION §Engine version](05_DETECTION.md))
|
||||
read *not found*. ([spike-notes §15](spike-notes.md), [05_DETECTION §Engine version](05_DETECTION.md)) Read since on the games
|
||||
in the database: KEEP IT ON HER 5.8 and Wuthering Waves 4.26.2; Phantom Blade Zero, Hogwarts Legacy and Mithril name no
|
||||
version in their executables, and an Xbox game's executable cannot be read outside its package (Valor Mortis).
|
||||
@@ -121,6 +121,15 @@ rather than of an instance.
|
||||
> `spike-notes` §8 and §H5 — so item 3's counter has nothing to count on this route. That is
|
||||
> a separate finding with its own consequences for HANDOFF item 3, and it does not belong to
|
||||
> this entry.
|
||||
>
|
||||
> **2026-11-06 (beta.34, D84): a fifth id is decoded, and not by guess.** `kFeatureDLSS_NR` (1004),
|
||||
> DLSS 5's neural rendering, comes from Streamline `v2.14.16`'s own `sl_core_types.h`, re-vendored for it
|
||||
> (`src/native/third_party/streamline/README.md`) — row O4's warning holds: no id is mapped from a number seen
|
||||
> arriving. Until then an evaluation of it fell to `FL_FEAT_SL_UNDECODED`, which the Agent does not store. It
|
||||
> is its own fact (`FL_FEAT_SL_NEURAL_RENDERING`, from the drain word, never from the decoded `upscaler`
|
||||
> byte — the rule above), never an upscaler; the census counts it in a bucket of its own
|
||||
> (`SlCensus.WithNeuralRendering`), so the buckets still add up. Whether a real game evaluates it through
|
||||
> `slEvaluateFeature` is owner-only item 30(a), with its table in `spike-notes` §26.
|
||||
|
||||
<details>
|
||||
<summary>The entry as it stood while it was open, including the pre-committed table with its two holes</summary>
|
||||
|
||||
@@ -50,3 +50,4 @@ Each section below lives in its own file under `docs/spike-notes/`, moved verbat
|
||||
| §24 | The whole gate on .NET 11 RC3 — what the alpha line's SDK asks of the source (2026-10-31, beta.32, D73–D76) | [`spike-notes/24-dotnet11-probe.md`](spike-notes/24-dotnet11-probe.md) |
|
||||
| §25 | Xbox app / Microsoft Store (GDK) titles — the layout, the launch chain, the image paths (2026-11-03, beta.33, D77–D82) | [`spike-notes/25-xbox-gdk.md`](spike-notes/25-xbox-gdk.md) |
|
||||
| §26 | DLSS 5 on Hogwarts Legacy, Dynamic frame generation on Phantom Blade Zero, and Streamline 2.12 → 2.14.16 (2026-11-06, beta.34, D83, D84) | [`spike-notes/26-dlss5-dynamic-streamline.md`](spike-notes/26-dlss5-dynamic-streamline.md) |
|
||||
| §27 | Switching to Games, and a language change that lands elsewhere (2026-11-06, beta.34) | [`spike-notes/27-games-page-2026-11-06.md`](spike-notes/27-games-page-2026-11-06.md) |
|
||||
@@ -0,0 +1,41 @@
|
||||
## 27 · Switching to Games, and a language change that lands elsewhere *(2026-11-06, beta.34)*
|
||||
|
||||
**Why this was measured.** The owner, 2026-11-06: switching from any page to Games stalls about 0.5–1.5 s before the
|
||||
page appears; and changing the language in Settings brings back the last content page (a game's detail) instead of
|
||||
Settings. §21 (beta.23) had measured the library at 275 ms for 48 games and left it, the grid non-virtualizing by the
|
||||
owner's decision (2026-10-15); the library has 65 games now.
|
||||
|
||||
**What the code showed** (read, then measured): every page is transient and rebuilt per visit; `GamesViewModel` read the
|
||||
settings, the games and the per-game session summary on the UI thread (Microsoft.Data.Sqlite completes its asynchronous
|
||||
calls synchronously), then asked for every executable's file **and showed no card until all had answered** — 39 of the
|
||||
owner's 41 Steam games are on the USB drive D:, which sleeps — and cleared and re-added every card on each read; the list
|
||||
view's `DataGrid` had no height bound and built every row. WPF UI's `NavigationCacheMode` would not have helped: 4.3.0
|
||||
reads it only when the NavigationView has neither a service provider nor a page provider, and this App sets one. The
|
||||
language: `ShellHost` remembered only pages opened from code (`PageNavigator`), never a pane click.
|
||||
|
||||
**The decision table, written before the runs:** fix what keeps the first card from appearing, what rebuilds a page on
|
||||
every visit, and what blocks the UI thread ≥ 50 ms; leave the grid non-virtualizing (the owner's decision); record the
|
||||
rest.
|
||||
|
||||
**How.** A scratch xUnit test over the App's own `GamesViewModel` and `GamesPage` (not committed — it times, and a timing
|
||||
assertion in CI is a flake), Release, on the dev PC of §21: a scratch ledger shaped like the owner's — 65 games, a third
|
||||
with a session — with the first executable check held **800 ms** (a USB drive waking) and every later one answering at
|
||||
once. Seven iterations a run, the median; three runs a side, the code before this change (PR-3's tree) and after it.
|
||||
*First cards*: from the view model's construction to all 65 cards listed. *Build*: a new page laid out at 1200×900 with
|
||||
its 65 cards. *Revisit*: before, a new page again (every visit built one); after, the kept page laid out again.
|
||||
|
||||
| | before (three runs) | after (three runs) |
|
||||
|---|---|---|
|
||||
| First cards | 822 – 830 ms | 10 – 15 ms |
|
||||
| Build (first visit) | 165 – 197 ms | 164 – 223 ms — the same work, run-to-run noise |
|
||||
| Revisit | 181 – 215 ms | 15 – 16 ms |
|
||||
|
||||
**Built** (beta.34): the window keeps the library page it built (`Services.WindowPageCache`, the window's own page
|
||||
provider, set after `INavigationService.SetNavigationControl`) and the page reads the library again each time it is shown
|
||||
(`GamesViewModel.Attach`); the library is read on the thread pool; the cards are listed first and the executable checks
|
||||
follow, each card getting its *Not installed* pill when its check answers; a read keeps every card that would look the
|
||||
same (`GameCardViewModel.LooksLike`, `GamesViewModel.Sync` — no `Clear`); the list view is bounded (`MaxHeight` 640).
|
||||
`ShellHost` notes every page the live window shows, so a rebuild opens on Settings after a change made there.
|
||||
|
||||
**Left as it was:** the first visit's build (≈ 2.5–3.4 ms a card at 65) — the non-virtualizing grid's cost, unchanged by
|
||||
decision; a page kept per window holds its 65 cards' visuals for the window's life.
|
||||
+5
-1
@@ -59,6 +59,9 @@ stopped, hooking turned off — each with one button that only says you have rea
|
||||
## Games
|
||||
|
||||
- **Search games**; sort by **Name**, **Last played** or **Playtime**; **Show as a list** or **Show as a grid**.
|
||||
- **Filters** (since 0.1.0-beta.34): by **store**, **engine**, **state** (Hooking on, Hooking off, Anti-cheat, Exception,
|
||||
Not recorded), **installed** and **played**; the title then says how many of your games are shown. **Clear filters**
|
||||
shows them all again.
|
||||
- **Refresh** reads your library again: it offers games newly installed through a store, and marks a game whose `.exe`
|
||||
is gone as *Not installed*. The agent removes such a game by itself after ten minutes when it has no sessions and its
|
||||
drive is connected — never one where anti-cheat was found (**Settings ▸ Data ▸ Remove uninstalled games** turns this
|
||||
@@ -108,7 +111,8 @@ It opens from a session row, from the Dashboard, and from the notice when a sess
|
||||
|
||||
Tick **2 to 5 sessions**, from any of your games, and press **Compare**: one frame-rate curve per measured session, and
|
||||
a table with the best value of each row in bold. Comparing a measured session with an unmeasured one asks first,
|
||||
because they measured different things.
|
||||
because they measured different things. The list holds every session; narrow it by **game**, **tier** (measured or
|
||||
not) and **frame generation** — a session you ticked stays in the list. **Clear selection** unticks them all.
|
||||
|
||||
## Logs
|
||||
|
||||
|
||||
@@ -42,7 +42,7 @@ The link under them, *Read what the hook does and does not do*, opens the safety
|
||||
| Setting | What it does | Default |
|
||||
|---|---|---|
|
||||
| **Theme** | Follow system, Light or Dark. Applies at once. | Follow system |
|
||||
| **Language** | English, Tiếng Việt or 日本語. The window is rebuilt in the new language at once. | English |
|
||||
| **Language** | English, Tiếng Việt or 日本語. The window is rebuilt in the new language at once, and stays on Settings (since 0.1.0-beta.34; before, it could open on the last game you looked at). | English |
|
||||
|
||||
## Games
|
||||
|
||||
|
||||
@@ -163,10 +163,12 @@
|
||||
</ItemsControl>
|
||||
</StackPanel>
|
||||
|
||||
<!-- beta.34 (D86): our copy of WPF UI's LeftFluent item template, so the selected page keeps its label (Styles/FrameLedger.xaml). -->
|
||||
<ui:NavigationView x:Name="RootNavigation"
|
||||
Grid.Row="3"
|
||||
IsBackButtonVisible="Collapsed"
|
||||
IsPaneToggleVisible="False"
|
||||
ItemTemplate="{StaticResource FlLeftFluentNavigationViewItemTemplate}"
|
||||
PaneDisplayMode="LeftFluent">
|
||||
<ui:NavigationView.MenuItems>
|
||||
<ui:NavigationViewItem Content="{x:Static res:Strings.Nav_Dashboard}"
|
||||
|
||||
@@ -45,8 +45,11 @@ public partial class MainWindow : FluentWindow
|
||||
theme.Apply(appearance.Theme, null);
|
||||
InitializeComponent();
|
||||
|
||||
RootNavigation.SetPageProviderService(pages);
|
||||
navigation.SetNavigationControl(RootNavigation);
|
||||
// beta.34: this window's own provider, set AFTER SetNavigationControl — which hands the NavigationView the
|
||||
// container's provider (upstream 4.3.0 NavigationService.SetNavigationControl) and would replace one set before it.
|
||||
// It keeps the library page for the window's life (WindowPageCache); every other page is the container's.
|
||||
RootNavigation.SetPageProviderService(new WindowPageCache(pages));
|
||||
snackbar.SetSnackbarPresenter(SnackbarPresenter);
|
||||
dialogs.SetDialogHost(DialogHost);
|
||||
|
||||
|
||||
@@ -18,18 +18,44 @@
|
||||
<ui:TextBlock Margin="0,16,0,0" Style="{StaticResource SecondaryText}" TextWrapping="Wrap" Text="{x:Static vm:CompareViewModel.EmptyText}"
|
||||
Visibility="{Binding ViewModel.IsEmpty, Converter={StaticResource BoolToVis}}" />
|
||||
|
||||
<Grid Margin="0,16,0,0" Visibility="{Binding ViewModel.IsEmpty, Converter={StaticResource InverseBoolToVis}}">
|
||||
<Grid.ColumnDefinitions>
|
||||
<ColumnDefinition Width="*" />
|
||||
<ColumnDefinition Width="Auto" />
|
||||
<ColumnDefinition Width="Auto" />
|
||||
</Grid.ColumnDefinitions>
|
||||
<ui:TextBlock Grid.Column="0" FontTypography="Subtitle" Text="{x:Static vm:CompareViewModel.PickHeader}" />
|
||||
<ui:TextBlock Grid.Column="1" Margin="0,0,16,0" VerticalAlignment="Center" Style="{StaticResource SecondaryText}" Text="{Binding ViewModel.SelectedText}" />
|
||||
<ui:Button Grid.Column="2" Appearance="Primary" Command="{Binding ViewModel.CompareCommand}" IsEnabled="{Binding ViewModel.CanCompare}"
|
||||
Content="{x:Static vm:CompareViewModel.RunText}" Icon="{ui:SymbolIcon ArrowSwap24}" />
|
||||
</Grid>
|
||||
<!-- beta.34 (owner request 2026-11-06, D85): the filters - game, tier, frame generation - over every session, and how
|
||||
many the list holds; a ticked session stays listed whatever they say. -->
|
||||
<WrapPanel Margin="0,16,0,0" Orientation="Horizontal"
|
||||
Visibility="{Binding ViewModel.IsEmpty, Converter={StaticResource InverseBoolToVis}}">
|
||||
<ComboBox MinWidth="220" Margin="0,0,8,8" VerticalAlignment="Center"
|
||||
AutomationProperties.Name="{x:Static res:Strings.A11y_Compare_Filter_Game}"
|
||||
DisplayMemberPath="Label" ItemsSource="{Binding ViewModel.Games}"
|
||||
SelectedValue="{Binding ViewModel.GameFilter, Mode=TwoWay}" SelectedValuePath="Value" />
|
||||
<ComboBox MinWidth="180" Margin="0,0,8,8" VerticalAlignment="Center"
|
||||
AutomationProperties.Name="{x:Static res:Strings.A11y_Compare_Filter_Tier}"
|
||||
DisplayMemberPath="Label" ItemsSource="{Binding ViewModel.Tiers}"
|
||||
SelectedValue="{Binding ViewModel.TierFilter, Mode=TwoWay}" SelectedValuePath="Value" />
|
||||
<ComboBox MinWidth="240" Margin="0,0,8,8" VerticalAlignment="Center"
|
||||
AutomationProperties.Name="{x:Static res:Strings.A11y_Compare_Filter_Fg}"
|
||||
DisplayMemberPath="Label" ItemsSource="{Binding ViewModel.FrameGenerationChoices}"
|
||||
SelectedValue="{Binding ViewModel.FrameGenerationFilter, Mode=TwoWay}" SelectedValuePath="Value" />
|
||||
<ui:Button Margin="0,0,16,8" VerticalAlignment="Center" Appearance="Secondary"
|
||||
Command="{Binding ViewModel.ClearFiltersCommand}"
|
||||
Content="{x:Static vm:CompareViewModel.ClearFiltersText}" Icon="{ui:SymbolIcon FilterDismiss24}" />
|
||||
<ui:TextBlock Margin="0,0,0,8" VerticalAlignment="Center" Style="{StaticResource SecondaryText}" Text="{Binding ViewModel.CountText}" />
|
||||
</WrapPanel>
|
||||
|
||||
<!-- beta.34: the selection bar beside what it acts on - it sat at the window's far right, a full width away from the list. -->
|
||||
<StackPanel Margin="0,8,0,0" Orientation="Horizontal"
|
||||
Visibility="{Binding ViewModel.IsEmpty, Converter={StaticResource InverseBoolToVis}}">
|
||||
<ui:TextBlock Margin="0,0,16,0" VerticalAlignment="Center" FontTypography="Subtitle" Text="{x:Static vm:CompareViewModel.PickHeader}" />
|
||||
<ui:TextBlock Margin="0,0,16,0" VerticalAlignment="Center" Style="{StaticResource SecondaryText}" Text="{Binding ViewModel.SelectedText}" />
|
||||
<ui:Button Margin="0,0,8,0" Appearance="Secondary" Command="{Binding ViewModel.ClearSelectionCommand}"
|
||||
Content="{x:Static vm:CompareViewModel.ClearSelectionText}" />
|
||||
<ui:Button Appearance="Primary" Command="{Binding ViewModel.CompareCommand}" IsEnabled="{Binding ViewModel.CanCompare}"
|
||||
Content="{x:Static vm:CompareViewModel.RunText}" Icon="{ui:SymbolIcon ArrowSwap24}" />
|
||||
</StackPanel>
|
||||
|
||||
<!--
|
||||
beta.34: columns sized to what they hold, and one filler column after them - three star columns spread a wide
|
||||
window into gaps, and the Tier column was exactly its header's width, so "Tier" and "FPS" touched. The date sorts
|
||||
by when, not by its text; the settings-changed cell says so in words, or shows a dash.
|
||||
-->
|
||||
<DataGrid Margin="0,8,0,0" MaxHeight="320" AutoGenerateColumns="False" CanUserAddRows="False" HeadersVisibility="Column"
|
||||
ItemsSource="{Binding ViewModel.Candidates}" SelectionMode="Single"
|
||||
Visibility="{Binding ViewModel.IsEmpty, Converter={StaticResource InverseBoolToVis}}">
|
||||
@@ -44,18 +70,23 @@
|
||||
</DataTemplate>
|
||||
</DataGridTemplateColumn.CellTemplate>
|
||||
</DataGridTemplateColumn>
|
||||
<DataGridTextColumn Header="{x:Static res:Strings.Compare_Col_Game}" Binding="{Binding GameName}" IsReadOnly="True" Width="2*" />
|
||||
<DataGridTextColumn Header="{x:Static res:Strings.Compare_Col_Date}" Binding="{Binding DateText}" IsReadOnly="True" Width="*" />
|
||||
<DataGridTextColumn Header="{x:Static res:Strings.Compare_Col_Tier}" Binding="{Binding TierText}" IsReadOnly="True" Width="Auto" />
|
||||
<DataGridTextColumn Header="{x:Static res:Strings.Compare_Col_Fps}" Binding="{Binding ReadoutLine}" IsReadOnly="True" Width="2*" />
|
||||
<DataGridTemplateColumn Header="{x:Static res:Strings.Compare_Col_MidSession}" IsReadOnly="True">
|
||||
<DataGridTextColumn Header="{x:Static res:Strings.Compare_Col_Game}" Binding="{Binding GameName}" IsReadOnly="True" Width="Auto" MinWidth="220" />
|
||||
<DataGridTextColumn Header="{x:Static res:Strings.Compare_Col_Date}" Binding="{Binding DateText}" SortMemberPath="StartedAt" IsReadOnly="True" Width="Auto" MinWidth="150" />
|
||||
<DataGridTextColumn Header="{x:Static res:Strings.Compare_Col_Tier}" Binding="{Binding TierText}" IsReadOnly="True" Width="Auto" MinWidth="64" />
|
||||
<DataGridTextColumn Header="{x:Static res:Strings.Compare_Col_Fps}" Binding="{Binding ReadoutLine}" IsReadOnly="True" Width="Auto" MinWidth="220" />
|
||||
<DataGridTemplateColumn Header="{x:Static res:Strings.Compare_Col_MidSession}" IsReadOnly="True" Width="Auto" MinWidth="150" SortMemberPath="SettingsChangedMidSession">
|
||||
<DataGridTemplateColumn.CellTemplate>
|
||||
<DataTemplate DataType="{x:Type vm:CompareCandidateViewModel}">
|
||||
<ui:SymbolIcon Symbol="Warning24" Foreground="{DynamicResource SystemFillColorCautionBrush}"
|
||||
Visibility="{Binding SettingsChangedMidSession, Converter={StaticResource BoolToVis}}" />
|
||||
<StackPanel Margin="4,0" Orientation="Horizontal" VerticalAlignment="Center">
|
||||
<ui:SymbolIcon Margin="0,0,6,0" Symbol="Warning24" Foreground="{DynamicResource SystemFillColorCautionBrush}"
|
||||
Visibility="{Binding SettingsChangedMidSession, Converter={StaticResource BoolToVis}}" />
|
||||
<TextBlock VerticalAlignment="Center" Text="{Binding SettingsChangedText}" />
|
||||
</StackPanel>
|
||||
</DataTemplate>
|
||||
</DataGridTemplateColumn.CellTemplate>
|
||||
</DataGridTemplateColumn>
|
||||
<!-- the filler: the width the columns above do not need, so they stay together on a wide window -->
|
||||
<DataGridTemplateColumn Width="*" CanUserSort="False" CanUserResize="False" IsReadOnly="True" />
|
||||
</DataGrid.Columns>
|
||||
</DataGrid>
|
||||
|
||||
@@ -75,19 +106,25 @@
|
||||
<charts:CompareChart x:Name="Chart" Margin="0,6,0,0" Height="340" />
|
||||
|
||||
<ui:TextBlock Margin="0,16,0,0" FontTypography="Subtitle" Text="{x:Static vm:CompareViewModel.TableHeader}" />
|
||||
<!-- the header row: one label per compared session -->
|
||||
<ItemsControl Margin="0,6,0,0" ItemsSource="{Binding ViewModel.Compared}">
|
||||
<ItemsControl.ItemsPanel>
|
||||
<ItemsPanelTemplate>
|
||||
<UniformGrid Rows="1" />
|
||||
</ItemsPanelTemplate>
|
||||
</ItemsControl.ItemsPanel>
|
||||
<ItemsControl.ItemTemplate>
|
||||
<DataTemplate DataType="{x:Type vm:CompareCandidateViewModel}">
|
||||
<ui:TextBlock Margin="4,0" Style="{StaticResource SecondaryText}" FontTypography="Caption" TextWrapping="Wrap" Text="{Binding Label}" />
|
||||
</DataTemplate>
|
||||
</ItemsControl.ItemTemplate>
|
||||
</ItemsControl>
|
||||
<!-- the header row: the metric column's own header, then one label per compared session - laid out as every row
|
||||
below is (a 140-px metric cell, then the sessions sharing the rest), so each label sits over its column;
|
||||
beta.34: it spread over the whole width, the 140 px included, and drifted left of its values. -->
|
||||
<DockPanel Margin="0,6,0,0">
|
||||
<ui:TextBlock DockPanel.Dock="Left" Width="140" Style="{StaticResource SecondaryText}" FontTypography="Caption"
|
||||
Text="{x:Static vm:CompareViewModel.MetricHeader}" />
|
||||
<ItemsControl ItemsSource="{Binding ViewModel.Compared}">
|
||||
<ItemsControl.ItemsPanel>
|
||||
<ItemsPanelTemplate>
|
||||
<UniformGrid Rows="1" />
|
||||
</ItemsPanelTemplate>
|
||||
</ItemsControl.ItemsPanel>
|
||||
<ItemsControl.ItemTemplate>
|
||||
<DataTemplate DataType="{x:Type vm:CompareCandidateViewModel}">
|
||||
<ui:TextBlock Margin="4,0" Style="{StaticResource SecondaryText}" FontTypography="Caption" TextWrapping="Wrap" Text="{Binding Label}" />
|
||||
</DataTemplate>
|
||||
</ItemsControl.ItemTemplate>
|
||||
</ItemsControl>
|
||||
</DockPanel>
|
||||
<ItemsControl ItemsSource="{Binding ViewModel.Rows}">
|
||||
<ItemsControl.ItemTemplate>
|
||||
<DataTemplate DataType="{x:Type vm:CompareRowViewModel}">
|
||||
|
||||
@@ -62,6 +62,36 @@
|
||||
Icon="{ui:SymbolIcon Add24}" />
|
||||
</Grid>
|
||||
|
||||
<!-- beta.34 (owner request 2026-11-06, D85): the filters - store, engine, state, installed, played - beside the search
|
||||
and sort above; each list names its "everything" first, and the stores and engines are the library's own. -->
|
||||
<WrapPanel Margin="0,12,0,0" Orientation="Horizontal"
|
||||
Visibility="{Binding ViewModel.IsEmpty, Converter={StaticResource InverseBoolToVis}}">
|
||||
<ComboBox MinWidth="150" Margin="0,0,8,8" VerticalAlignment="Center"
|
||||
AutomationProperties.Name="{x:Static res:Strings.A11y_Games_Filter_Store}"
|
||||
DisplayMemberPath="Label" ItemsSource="{Binding ViewModel.Stores}"
|
||||
SelectedValue="{Binding ViewModel.StoreFilter, Mode=TwoWay}" SelectedValuePath="Value" />
|
||||
<ComboBox MinWidth="170" Margin="0,0,8,8" VerticalAlignment="Center"
|
||||
AutomationProperties.Name="{x:Static res:Strings.A11y_Games_Filter_Engine}"
|
||||
DisplayMemberPath="Label" ItemsSource="{Binding ViewModel.Engines}"
|
||||
SelectedValue="{Binding ViewModel.EngineFilter, Mode=TwoWay}" SelectedValuePath="Value" />
|
||||
<ComboBox MinWidth="150" Margin="0,0,8,8" VerticalAlignment="Center"
|
||||
AutomationProperties.Name="{x:Static res:Strings.A11y_Games_Filter_State}"
|
||||
DisplayMemberPath="Label" ItemsSource="{Binding ViewModel.States}"
|
||||
SelectedValue="{Binding ViewModel.StateFilter, Mode=TwoWay}" SelectedValuePath="Value" />
|
||||
<ComboBox MinWidth="150" Margin="0,0,8,8" VerticalAlignment="Center"
|
||||
AutomationProperties.Name="{x:Static res:Strings.A11y_Games_Filter_Installed}"
|
||||
DisplayMemberPath="Label" ItemsSource="{Binding ViewModel.InstalledChoices}"
|
||||
SelectedValue="{Binding ViewModel.InstalledFilter, Mode=TwoWay}" SelectedValuePath="Value" />
|
||||
<ComboBox MinWidth="150" Margin="0,0,8,8" VerticalAlignment="Center"
|
||||
AutomationProperties.Name="{x:Static res:Strings.A11y_Games_Filter_Played}"
|
||||
DisplayMemberPath="Label" ItemsSource="{Binding ViewModel.PlayedChoices}"
|
||||
SelectedValue="{Binding ViewModel.PlayedFilter, Mode=TwoWay}" SelectedValuePath="Value" />
|
||||
<ui:Button Margin="0,0,0,8" VerticalAlignment="Center" Appearance="Secondary"
|
||||
Command="{Binding ViewModel.ClearFiltersCommand}"
|
||||
Content="{x:Static vm:GamesViewModel.ClearFiltersText}"
|
||||
Icon="{ui:SymbolIcon FilterDismiss24}" />
|
||||
</WrapPanel>
|
||||
|
||||
<ui:TextBlock Margin="0,16,0,0" Style="{StaticResource SecondaryText}" TextWrapping="Wrap"
|
||||
Text="{x:Static vm:GamesViewModel.EmptyText}"
|
||||
Visibility="{Binding ViewModel.IsEmpty, Converter={StaticResource BoolToVis}}" />
|
||||
@@ -123,8 +153,10 @@
|
||||
</ItemsControl.ItemTemplate>
|
||||
</ItemsControl>
|
||||
|
||||
<!-- The list: one row per game across the width; double-click or Enter opens it. -->
|
||||
<DataGrid x:Name="GameList" Margin="0,16,0,0" AutoGenerateColumns="False" CanUserAddRows="False" CanUserDeleteRows="False"
|
||||
<!-- The list: one row per game across the width; double-click or Enter opens it. Bounded since beta.34, as the
|
||||
Sessions grid is since beta.23: inside the page's scroller it was measured with no height limit and built every
|
||||
row, a Play button each (spike-notes §21, §27). -->
|
||||
<DataGrid x:Name="GameList" Margin="0,16,0,0" MaxHeight="640" AutoGenerateColumns="False" CanUserAddRows="False" CanUserDeleteRows="False"
|
||||
CanUserSortColumns="False" HeadersVisibility="Column" IsReadOnly="True" SelectionMode="Single"
|
||||
ItemsSource="{Binding ViewModel.Games}"
|
||||
MouseDoubleClick="OnListDoubleClick" KeyDown="OnListKeyDown"
|
||||
|
||||
@@ -108,14 +108,9 @@ public sealed class GameLibrary
|
||||
return [];
|
||||
}
|
||||
|
||||
var names = new Dictionary<long, string>();
|
||||
foreach (long gameId in rows.Select(static r => r.GameId).Distinct())
|
||||
{
|
||||
GameRow? game = await _games.FindByIdAsync(gameId, ct).ConfigureAwait(false);
|
||||
names[gameId] = game?.Name ?? Strings.Common_NotAvailable;
|
||||
}
|
||||
|
||||
return [.. rows.Select(r => new RecentSession(r, names[r.GameId]))];
|
||||
// One read of the library's names (beta.34): Compare now lists every session, and a read per game was a query each.
|
||||
Dictionary<long, string> names = (await _games.ListAsync(ct).ConfigureAwait(false)).ToDictionary(static g => g.Id, static g => g.Name);
|
||||
return [.. rows.Select(r => new RecentSession(r, names.GetValueOrDefault(r.GameId) ?? Strings.Common_NotAvailable))];
|
||||
}
|
||||
|
||||
public async Task<LibraryTotals> TotalsAsync(CancellationToken ct = default)
|
||||
|
||||
@@ -35,6 +35,10 @@ public sealed class ShellHost(IServiceProvider services, INavigationService navi
|
||||
MainWindow window = services.GetRequiredService<MainWindow>();
|
||||
window.Closing += OnClosing;
|
||||
window.Closed += OnClosed;
|
||||
// beta.34 (owner request 2026-11-06): every page the window shows is the one a rebuild opens on — a click in the pane
|
||||
// included, which never went through PageNavigator. A language changed on Settings stays on Settings; it came back
|
||||
// on the last page opened from code (a game's page, typically).
|
||||
window.RootNavigation.Navigated += (_, e) => NoteShown(ReferenceEquals(window, _current), e.Page);
|
||||
_current = window;
|
||||
window.Show();
|
||||
Interlocked.Exchange(ref _handle, new System.Windows.Interop.WindowInteropHelper(window).Handle);
|
||||
@@ -71,6 +75,21 @@ public sealed class ShellHost(IServiceProvider services, INavigationService navi
|
||||
/// <summary>The page the shell will open on, kept across a rebuild.</summary>
|
||||
public void Remember(Type page) => _page = page;
|
||||
|
||||
/// <summary>The page a rebuild opens on (beta.34: the page on screen).</summary>
|
||||
internal Type Page => _page;
|
||||
|
||||
/// <summary>
|
||||
/// A page the live window shows (beta.34): remembered whichever way it was reached — the pane, the keyboard, a link, code.
|
||||
/// The old window of a rebuild, closing, changes nothing.
|
||||
/// </summary>
|
||||
internal void NoteShown(bool live, object? page)
|
||||
{
|
||||
if (live && page is not null)
|
||||
{
|
||||
_page = page.GetType();
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// A new window in the current UI culture; the old one closes after the new one is up. The long-lived pieces that
|
||||
/// read their text once — the tray's menu, the Agent pill — read it again (<see cref="ILanguageFollower"/>, beta.15).
|
||||
|
||||
@@ -0,0 +1,60 @@
|
||||
// SPDX-License-Identifier: GPL-3.0-only
|
||||
// Copyright (C) 2026 poli0981 - additional terms under GPLv3 section 7: see NOTICE
|
||||
|
||||
using FrameLedger.App.Pages;
|
||||
using Wpf.Ui.Abstractions;
|
||||
|
||||
namespace FrameLedger.App.Services;
|
||||
|
||||
/// <summary>
|
||||
/// The window's page provider (beta.34, owner request 2026-11-06: "switching to Games stalls 0.5–1.5 s"): the container's,
|
||||
/// except that the library page is built once per window and shown again on every later visit — its cards already laid
|
||||
/// out — and reads the library again in the background (<see cref="ViewModels.GamesViewModel.Attach"/>).
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>
|
||||
/// <b>Why not WPF UI's own cache.</b> <c>NavigationViewItem.NavigationCacheMode</c> is read only when the NavigationView has
|
||||
/// neither a service provider nor a page provider (upstream 4.3.0 <c>NavigationView.Navigation.cs</c>,
|
||||
/// <c>GetNavigationItemInstance</c>): this App sets a page provider, so the attribute would have changed nothing.
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// <b>Why per window.</b> A language change builds a new window (<see cref="ShellHost.Rebuild"/>) and shows it before the
|
||||
/// old one closes: a page shared between them would be asked into a second frame while the first still holds it, and would
|
||||
/// keep the old language's text. One instance of this class per <see cref="MainWindow"/> keeps both apart — the new window
|
||||
/// builds its own page in the new language.
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// The pages stay transient in the container (<c>16_WPFUI_SYNTAX</c> §Navigation); only <see cref="Kept"/> are held, and
|
||||
/// only by the window that built them.
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public sealed class WindowPageCache(INavigationViewPageProvider inner) : INavigationViewPageProvider
|
||||
{
|
||||
private readonly INavigationViewPageProvider _inner = inner ?? throw new ArgumentNullException(nameof(inner));
|
||||
private readonly Dictionary<Type, object> _kept = [];
|
||||
|
||||
/// <summary>The pages a window keeps: the library, the one page whose build grows with the data (<c>spike-notes</c> §21, §27).</summary>
|
||||
public static IReadOnlySet<Type> Kept { get; } = new HashSet<Type> { typeof(GamesPage) };
|
||||
|
||||
public object? GetPage(Type pageType)
|
||||
{
|
||||
ArgumentNullException.ThrowIfNull(pageType);
|
||||
if (!Kept.Contains(pageType))
|
||||
{
|
||||
return _inner.GetPage(pageType);
|
||||
}
|
||||
|
||||
if (_kept.TryGetValue(pageType, out object? page))
|
||||
{
|
||||
return page;
|
||||
}
|
||||
|
||||
page = _inner.GetPage(pageType);
|
||||
if (page is not null)
|
||||
{
|
||||
_kept[pageType] = page;
|
||||
}
|
||||
|
||||
return page;
|
||||
}
|
||||
}
|
||||
Generated
+90
@@ -29,6 +29,14 @@ public static class Strings
|
||||
/// <summary>Every key, for an audit that walks them.</summary>
|
||||
public static IReadOnlyList<string> Keys { get; } =
|
||||
[
|
||||
nameof(A11y_Compare_Filter_Fg),
|
||||
nameof(A11y_Compare_Filter_Game),
|
||||
nameof(A11y_Compare_Filter_Tier),
|
||||
nameof(A11y_Games_Filter_Engine),
|
||||
nameof(A11y_Games_Filter_Installed),
|
||||
nameof(A11y_Games_Filter_Played),
|
||||
nameof(A11y_Games_Filter_State),
|
||||
nameof(A11y_Games_Filter_Store),
|
||||
nameof(A11y_Games_Sort),
|
||||
nameof(A11y_Logs_Level),
|
||||
nameof(A11y_Logs_Source),
|
||||
@@ -161,14 +169,24 @@ public static class Strings
|
||||
nameof(Common_NotAvailable),
|
||||
nameof(Common_Ok),
|
||||
nameof(Common_Yes),
|
||||
nameof(Compare_ClearSelection),
|
||||
nameof(Compare_Col_Date),
|
||||
nameof(Compare_Col_Fps),
|
||||
nameof(Compare_Col_Game),
|
||||
nameof(Compare_Col_MidSession),
|
||||
nameof(Compare_Col_Tier),
|
||||
nameof(Compare_Count_Filtered_Format),
|
||||
nameof(Compare_Count_Format),
|
||||
nameof(Compare_Curves_Header),
|
||||
nameof(Compare_Empty),
|
||||
nameof(Compare_Export_Png),
|
||||
nameof(Compare_Filter_Fg_All),
|
||||
nameof(Compare_Filter_Fg_With),
|
||||
nameof(Compare_Filter_Fg_Without),
|
||||
nameof(Compare_Filter_Game_All),
|
||||
nameof(Compare_Filter_Tier_All),
|
||||
nameof(Compare_Filter_Tier_Measured),
|
||||
nameof(Compare_Filter_Tier_NotMeasured),
|
||||
nameof(Compare_Header),
|
||||
nameof(Compare_Legend_Format),
|
||||
nameof(Compare_Metric_AvgCpuLoad),
|
||||
@@ -199,6 +217,7 @@ public static class Strings
|
||||
nameof(Compare_Metric_TimeBelowRefresh),
|
||||
nameof(Compare_Metric_Vsync),
|
||||
nameof(Compare_Metric_Window),
|
||||
nameof(Compare_MidSession_Changed),
|
||||
nameof(Compare_Mixed_Body),
|
||||
nameof(Compare_Mixed_Legend),
|
||||
nameof(Compare_Mixed_Proceed),
|
||||
@@ -431,6 +450,7 @@ public static class Strings
|
||||
nameof(FgMix_State_Format),
|
||||
nameof(FgMix_Unclassified),
|
||||
nameof(FgMix_Unclassified_Note),
|
||||
nameof(Filter_Clear),
|
||||
nameof(FirstRun_Accept),
|
||||
nameof(FirstRun_Agent_Body),
|
||||
nameof(FirstRun_Agent_Header),
|
||||
@@ -583,8 +603,18 @@ public static class Strings
|
||||
nameof(Games_Card_Playtime_Format),
|
||||
nameof(Games_Card_Sessions_Format),
|
||||
nameof(Games_Empty),
|
||||
nameof(Games_Filter_Engine_All),
|
||||
nameof(Games_Filter_Engine_Unknown),
|
||||
nameof(Games_Filter_Installed_All),
|
||||
nameof(Games_Filter_Installed_Yes),
|
||||
nameof(Games_Filter_Played_All),
|
||||
nameof(Games_Filter_Played_Yes),
|
||||
nameof(Games_Filter_State_All),
|
||||
nameof(Games_Filter_Store_All),
|
||||
nameof(Games_Filter_Store_Manual),
|
||||
nameof(Games_Header),
|
||||
nameof(Games_Header_Count_Format),
|
||||
nameof(Games_Header_Filtered_Format),
|
||||
nameof(Games_List_Engine),
|
||||
nameof(Games_List_LastPlayed),
|
||||
nameof(Games_List_Name),
|
||||
@@ -1197,6 +1227,22 @@ public static class Strings
|
||||
nameof(Viewer_ChangesThisPc_Off),
|
||||
];
|
||||
|
||||
public static string A11y_Compare_Filter_Fg => ResourceManager.GetString(nameof(A11y_Compare_Filter_Fg), Culture) ?? nameof(A11y_Compare_Filter_Fg);
|
||||
|
||||
public static string A11y_Compare_Filter_Game => ResourceManager.GetString(nameof(A11y_Compare_Filter_Game), Culture) ?? nameof(A11y_Compare_Filter_Game);
|
||||
|
||||
public static string A11y_Compare_Filter_Tier => ResourceManager.GetString(nameof(A11y_Compare_Filter_Tier), Culture) ?? nameof(A11y_Compare_Filter_Tier);
|
||||
|
||||
public static string A11y_Games_Filter_Engine => ResourceManager.GetString(nameof(A11y_Games_Filter_Engine), Culture) ?? nameof(A11y_Games_Filter_Engine);
|
||||
|
||||
public static string A11y_Games_Filter_Installed => ResourceManager.GetString(nameof(A11y_Games_Filter_Installed), Culture) ?? nameof(A11y_Games_Filter_Installed);
|
||||
|
||||
public static string A11y_Games_Filter_Played => ResourceManager.GetString(nameof(A11y_Games_Filter_Played), Culture) ?? nameof(A11y_Games_Filter_Played);
|
||||
|
||||
public static string A11y_Games_Filter_State => ResourceManager.GetString(nameof(A11y_Games_Filter_State), Culture) ?? nameof(A11y_Games_Filter_State);
|
||||
|
||||
public static string A11y_Games_Filter_Store => ResourceManager.GetString(nameof(A11y_Games_Filter_Store), Culture) ?? nameof(A11y_Games_Filter_Store);
|
||||
|
||||
public static string A11y_Games_Sort => ResourceManager.GetString(nameof(A11y_Games_Sort), Culture) ?? nameof(A11y_Games_Sort);
|
||||
|
||||
public static string A11y_Logs_Level => ResourceManager.GetString(nameof(A11y_Logs_Level), Culture) ?? nameof(A11y_Logs_Level);
|
||||
@@ -1461,6 +1507,8 @@ public static class Strings
|
||||
|
||||
public static string Common_Yes => ResourceManager.GetString(nameof(Common_Yes), Culture) ?? nameof(Common_Yes);
|
||||
|
||||
public static string Compare_ClearSelection => ResourceManager.GetString(nameof(Compare_ClearSelection), Culture) ?? nameof(Compare_ClearSelection);
|
||||
|
||||
public static string Compare_Col_Date => ResourceManager.GetString(nameof(Compare_Col_Date), Culture) ?? nameof(Compare_Col_Date);
|
||||
|
||||
public static string Compare_Col_Fps => ResourceManager.GetString(nameof(Compare_Col_Fps), Culture) ?? nameof(Compare_Col_Fps);
|
||||
@@ -1471,12 +1519,30 @@ public static class Strings
|
||||
|
||||
public static string Compare_Col_Tier => ResourceManager.GetString(nameof(Compare_Col_Tier), Culture) ?? nameof(Compare_Col_Tier);
|
||||
|
||||
public static string Compare_Count_Filtered_Format => ResourceManager.GetString(nameof(Compare_Count_Filtered_Format), Culture) ?? nameof(Compare_Count_Filtered_Format);
|
||||
|
||||
public static string Compare_Count_Format => ResourceManager.GetString(nameof(Compare_Count_Format), Culture) ?? nameof(Compare_Count_Format);
|
||||
|
||||
public static string Compare_Curves_Header => ResourceManager.GetString(nameof(Compare_Curves_Header), Culture) ?? nameof(Compare_Curves_Header);
|
||||
|
||||
public static string Compare_Empty => ResourceManager.GetString(nameof(Compare_Empty), Culture) ?? nameof(Compare_Empty);
|
||||
|
||||
public static string Compare_Export_Png => ResourceManager.GetString(nameof(Compare_Export_Png), Culture) ?? nameof(Compare_Export_Png);
|
||||
|
||||
public static string Compare_Filter_Fg_All => ResourceManager.GetString(nameof(Compare_Filter_Fg_All), Culture) ?? nameof(Compare_Filter_Fg_All);
|
||||
|
||||
public static string Compare_Filter_Fg_With => ResourceManager.GetString(nameof(Compare_Filter_Fg_With), Culture) ?? nameof(Compare_Filter_Fg_With);
|
||||
|
||||
public static string Compare_Filter_Fg_Without => ResourceManager.GetString(nameof(Compare_Filter_Fg_Without), Culture) ?? nameof(Compare_Filter_Fg_Without);
|
||||
|
||||
public static string Compare_Filter_Game_All => ResourceManager.GetString(nameof(Compare_Filter_Game_All), Culture) ?? nameof(Compare_Filter_Game_All);
|
||||
|
||||
public static string Compare_Filter_Tier_All => ResourceManager.GetString(nameof(Compare_Filter_Tier_All), Culture) ?? nameof(Compare_Filter_Tier_All);
|
||||
|
||||
public static string Compare_Filter_Tier_Measured => ResourceManager.GetString(nameof(Compare_Filter_Tier_Measured), Culture) ?? nameof(Compare_Filter_Tier_Measured);
|
||||
|
||||
public static string Compare_Filter_Tier_NotMeasured => ResourceManager.GetString(nameof(Compare_Filter_Tier_NotMeasured), Culture) ?? nameof(Compare_Filter_Tier_NotMeasured);
|
||||
|
||||
public static string Compare_Header => ResourceManager.GetString(nameof(Compare_Header), Culture) ?? nameof(Compare_Header);
|
||||
|
||||
public static string Compare_Legend_Format => ResourceManager.GetString(nameof(Compare_Legend_Format), Culture) ?? nameof(Compare_Legend_Format);
|
||||
@@ -1537,6 +1603,8 @@ public static class Strings
|
||||
|
||||
public static string Compare_Metric_Window => ResourceManager.GetString(nameof(Compare_Metric_Window), Culture) ?? nameof(Compare_Metric_Window);
|
||||
|
||||
public static string Compare_MidSession_Changed => ResourceManager.GetString(nameof(Compare_MidSession_Changed), Culture) ?? nameof(Compare_MidSession_Changed);
|
||||
|
||||
public static string Compare_Mixed_Body => ResourceManager.GetString(nameof(Compare_Mixed_Body), Culture) ?? nameof(Compare_Mixed_Body);
|
||||
|
||||
public static string Compare_Mixed_Legend => ResourceManager.GetString(nameof(Compare_Mixed_Legend), Culture) ?? nameof(Compare_Mixed_Legend);
|
||||
@@ -2001,6 +2069,8 @@ public static class Strings
|
||||
|
||||
public static string FgMix_Unclassified_Note => ResourceManager.GetString(nameof(FgMix_Unclassified_Note), Culture) ?? nameof(FgMix_Unclassified_Note);
|
||||
|
||||
public static string Filter_Clear => ResourceManager.GetString(nameof(Filter_Clear), Culture) ?? nameof(Filter_Clear);
|
||||
|
||||
public static string FirstRun_Accept => ResourceManager.GetString(nameof(FirstRun_Accept), Culture) ?? nameof(FirstRun_Accept);
|
||||
|
||||
public static string FirstRun_Agent_Body => ResourceManager.GetString(nameof(FirstRun_Agent_Body), Culture) ?? nameof(FirstRun_Agent_Body);
|
||||
@@ -2305,10 +2375,30 @@ public static class Strings
|
||||
|
||||
public static string Games_Empty => ResourceManager.GetString(nameof(Games_Empty), Culture) ?? nameof(Games_Empty);
|
||||
|
||||
public static string Games_Filter_Engine_All => ResourceManager.GetString(nameof(Games_Filter_Engine_All), Culture) ?? nameof(Games_Filter_Engine_All);
|
||||
|
||||
public static string Games_Filter_Engine_Unknown => ResourceManager.GetString(nameof(Games_Filter_Engine_Unknown), Culture) ?? nameof(Games_Filter_Engine_Unknown);
|
||||
|
||||
public static string Games_Filter_Installed_All => ResourceManager.GetString(nameof(Games_Filter_Installed_All), Culture) ?? nameof(Games_Filter_Installed_All);
|
||||
|
||||
public static string Games_Filter_Installed_Yes => ResourceManager.GetString(nameof(Games_Filter_Installed_Yes), Culture) ?? nameof(Games_Filter_Installed_Yes);
|
||||
|
||||
public static string Games_Filter_Played_All => ResourceManager.GetString(nameof(Games_Filter_Played_All), Culture) ?? nameof(Games_Filter_Played_All);
|
||||
|
||||
public static string Games_Filter_Played_Yes => ResourceManager.GetString(nameof(Games_Filter_Played_Yes), Culture) ?? nameof(Games_Filter_Played_Yes);
|
||||
|
||||
public static string Games_Filter_State_All => ResourceManager.GetString(nameof(Games_Filter_State_All), Culture) ?? nameof(Games_Filter_State_All);
|
||||
|
||||
public static string Games_Filter_Store_All => ResourceManager.GetString(nameof(Games_Filter_Store_All), Culture) ?? nameof(Games_Filter_Store_All);
|
||||
|
||||
public static string Games_Filter_Store_Manual => ResourceManager.GetString(nameof(Games_Filter_Store_Manual), Culture) ?? nameof(Games_Filter_Store_Manual);
|
||||
|
||||
public static string Games_Header => ResourceManager.GetString(nameof(Games_Header), Culture) ?? nameof(Games_Header);
|
||||
|
||||
public static string Games_Header_Count_Format => ResourceManager.GetString(nameof(Games_Header_Count_Format), Culture) ?? nameof(Games_Header_Count_Format);
|
||||
|
||||
public static string Games_Header_Filtered_Format => ResourceManager.GetString(nameof(Games_Header_Filtered_Format), Culture) ?? nameof(Games_Header_Filtered_Format);
|
||||
|
||||
public static string Games_List_Engine => ResourceManager.GetString(nameof(Games_List_Engine), Culture) ?? nameof(Games_List_Engine);
|
||||
|
||||
public static string Games_List_LastPlayed => ResourceManager.GetString(nameof(Games_List_LastPlayed), Culture) ?? nameof(Games_List_LastPlayed);
|
||||
|
||||
@@ -1121,6 +1121,50 @@
|
||||
<value>並べ替え</value>
|
||||
<comment>review</comment>
|
||||
</data>
|
||||
<data name="Games_Filter_Store_All" xml:space="preserve">
|
||||
<value>すべてのストア</value>
|
||||
<comment>review</comment>
|
||||
</data>
|
||||
<data name="Games_Filter_Store_Manual" xml:space="preserve">
|
||||
<value>手動で追加</value>
|
||||
<comment>review</comment>
|
||||
</data>
|
||||
<data name="Games_Filter_Engine_All" xml:space="preserve">
|
||||
<value>すべてのエンジン</value>
|
||||
<comment>review</comment>
|
||||
</data>
|
||||
<data name="Games_Filter_Engine_Unknown" xml:space="preserve">
|
||||
<value>エンジン不明</value>
|
||||
<comment>review</comment>
|
||||
</data>
|
||||
<data name="Games_Filter_State_All" xml:space="preserve">
|
||||
<value>すべての状態</value>
|
||||
<comment>review</comment>
|
||||
</data>
|
||||
<data name="Games_Filter_Installed_All" xml:space="preserve">
|
||||
<value>インストール済みかを問わない</value>
|
||||
<comment>review</comment>
|
||||
</data>
|
||||
<data name="Games_Filter_Installed_Yes" xml:space="preserve">
|
||||
<value>インストール済み</value>
|
||||
<comment>review</comment>
|
||||
</data>
|
||||
<data name="Games_Filter_Played_All" xml:space="preserve">
|
||||
<value>プレイ済みかを問わない</value>
|
||||
<comment>review</comment>
|
||||
</data>
|
||||
<data name="Games_Filter_Played_Yes" xml:space="preserve">
|
||||
<value>セッションあり</value>
|
||||
<comment>review</comment>
|
||||
</data>
|
||||
<data name="Games_Header_Filtered_Format" xml:space="preserve">
|
||||
<value>ゲーム · {0} / {1}</value>
|
||||
<comment>review</comment>
|
||||
</data>
|
||||
<data name="Filter_Clear" xml:space="preserve">
|
||||
<value>フィルターを解除</value>
|
||||
<comment>review</comment>
|
||||
</data>
|
||||
<data name="Games_Sort_LastPlayed" xml:space="preserve">
|
||||
<value>最後にプレイ</value>
|
||||
<comment>review</comment>
|
||||
@@ -1609,6 +1653,50 @@
|
||||
<value>{0} 件選択</value>
|
||||
<comment>review</comment>
|
||||
</data>
|
||||
<data name="Compare_Filter_Game_All" xml:space="preserve">
|
||||
<value>すべてのゲーム</value>
|
||||
<comment>review</comment>
|
||||
</data>
|
||||
<data name="Compare_Filter_Tier_All" xml:space="preserve">
|
||||
<value>すべての Tier</value>
|
||||
<comment>review</comment>
|
||||
</data>
|
||||
<data name="Compare_Filter_Tier_Measured" xml:space="preserve">
|
||||
<value>計測あり (Tier 1)</value>
|
||||
<comment>review</comment>
|
||||
</data>
|
||||
<data name="Compare_Filter_Tier_NotMeasured" xml:space="preserve">
|
||||
<value>計測なし (Tier 2)</value>
|
||||
<comment>review</comment>
|
||||
</data>
|
||||
<data name="Compare_Filter_Fg_All" xml:space="preserve">
|
||||
<value>フレーム生成の有無を問わない</value>
|
||||
<comment>review</comment>
|
||||
</data>
|
||||
<data name="Compare_Filter_Fg_With" xml:space="preserve">
|
||||
<value>フレーム生成あり</value>
|
||||
<comment>review</comment>
|
||||
</data>
|
||||
<data name="Compare_Filter_Fg_Without" xml:space="preserve">
|
||||
<value>フレーム生成なし</value>
|
||||
<comment>review</comment>
|
||||
</data>
|
||||
<data name="Compare_Count_Format" xml:space="preserve">
|
||||
<value>{0} 件のセッション</value>
|
||||
<comment>review</comment>
|
||||
</data>
|
||||
<data name="Compare_Count_Filtered_Format" xml:space="preserve">
|
||||
<value>{1} 件中 {0} 件のセッション</value>
|
||||
<comment>review</comment>
|
||||
</data>
|
||||
<data name="Compare_ClearSelection" xml:space="preserve">
|
||||
<value>選択を解除</value>
|
||||
<comment>review</comment>
|
||||
</data>
|
||||
<data name="Compare_MidSession_Changed" xml:space="preserve">
|
||||
<value>セッション中に変更</value>
|
||||
<comment>review</comment>
|
||||
</data>
|
||||
<data name="Compare_Table_Header" xml:space="preserve">
|
||||
<value>統計</value>
|
||||
<comment>review</comment>
|
||||
@@ -2588,6 +2676,38 @@
|
||||
<value>ゲームの並べ替え</value>
|
||||
<comment>review</comment>
|
||||
</data>
|
||||
<data name="A11y_Games_Filter_Store" xml:space="preserve">
|
||||
<value>ストアでゲームを絞り込む</value>
|
||||
<comment>review</comment>
|
||||
</data>
|
||||
<data name="A11y_Games_Filter_Engine" xml:space="preserve">
|
||||
<value>エンジンでゲームを絞り込む</value>
|
||||
<comment>review</comment>
|
||||
</data>
|
||||
<data name="A11y_Games_Filter_State" xml:space="preserve">
|
||||
<value>状態でゲームを絞り込む</value>
|
||||
<comment>review</comment>
|
||||
</data>
|
||||
<data name="A11y_Games_Filter_Installed" xml:space="preserve">
|
||||
<value>インストール状態でゲームを絞り込む</value>
|
||||
<comment>review</comment>
|
||||
</data>
|
||||
<data name="A11y_Games_Filter_Played" xml:space="preserve">
|
||||
<value>セッションでゲームを絞り込む</value>
|
||||
<comment>review</comment>
|
||||
</data>
|
||||
<data name="A11y_Compare_Filter_Game" xml:space="preserve">
|
||||
<value>ゲームでセッションを絞り込む</value>
|
||||
<comment>review</comment>
|
||||
</data>
|
||||
<data name="A11y_Compare_Filter_Tier" xml:space="preserve">
|
||||
<value>Tier でセッションを絞り込む</value>
|
||||
<comment>review</comment>
|
||||
</data>
|
||||
<data name="A11y_Compare_Filter_Fg" xml:space="preserve">
|
||||
<value>フレーム生成でセッションを絞り込む</value>
|
||||
<comment>review</comment>
|
||||
</data>
|
||||
<data name="A11y_Logs_Source" xml:space="preserve">
|
||||
<value>ログのソース</value>
|
||||
<comment>review</comment>
|
||||
|
||||
@@ -846,6 +846,39 @@
|
||||
<data name="Games_Sort_Label" xml:space="preserve">
|
||||
<value>Sort by</value>
|
||||
</data>
|
||||
<data name="Games_Filter_Store_All" xml:space="preserve">
|
||||
<value>All stores</value>
|
||||
</data>
|
||||
<data name="Games_Filter_Store_Manual" xml:space="preserve">
|
||||
<value>Added by hand</value>
|
||||
</data>
|
||||
<data name="Games_Filter_Engine_All" xml:space="preserve">
|
||||
<value>All engines</value>
|
||||
</data>
|
||||
<data name="Games_Filter_Engine_Unknown" xml:space="preserve">
|
||||
<value>Engine not identified</value>
|
||||
</data>
|
||||
<data name="Games_Filter_State_All" xml:space="preserve">
|
||||
<value>Any state</value>
|
||||
</data>
|
||||
<data name="Games_Filter_Installed_All" xml:space="preserve">
|
||||
<value>Installed or not</value>
|
||||
</data>
|
||||
<data name="Games_Filter_Installed_Yes" xml:space="preserve">
|
||||
<value>Installed</value>
|
||||
</data>
|
||||
<data name="Games_Filter_Played_All" xml:space="preserve">
|
||||
<value>Played or not</value>
|
||||
</data>
|
||||
<data name="Games_Filter_Played_Yes" xml:space="preserve">
|
||||
<value>With sessions</value>
|
||||
</data>
|
||||
<data name="Games_Header_Filtered_Format" xml:space="preserve">
|
||||
<value>Games · {0} of {1}</value>
|
||||
</data>
|
||||
<data name="Filter_Clear" xml:space="preserve">
|
||||
<value>Clear filters</value>
|
||||
</data>
|
||||
<data name="Games_Sort_LastPlayed" xml:space="preserve">
|
||||
<value>Last played</value>
|
||||
</data>
|
||||
@@ -1212,6 +1245,39 @@
|
||||
<data name="Compare_Selected_Format" xml:space="preserve">
|
||||
<value>{0} selected</value>
|
||||
</data>
|
||||
<data name="Compare_Filter_Game_All" xml:space="preserve">
|
||||
<value>All games</value>
|
||||
</data>
|
||||
<data name="Compare_Filter_Tier_All" xml:space="preserve">
|
||||
<value>Any tier</value>
|
||||
</data>
|
||||
<data name="Compare_Filter_Tier_Measured" xml:space="preserve">
|
||||
<value>Measured (Tier 1)</value>
|
||||
</data>
|
||||
<data name="Compare_Filter_Tier_NotMeasured" xml:space="preserve">
|
||||
<value>Not measured (Tier 2)</value>
|
||||
</data>
|
||||
<data name="Compare_Filter_Fg_All" xml:space="preserve">
|
||||
<value>With or without frame generation</value>
|
||||
</data>
|
||||
<data name="Compare_Filter_Fg_With" xml:space="preserve">
|
||||
<value>With frame generation</value>
|
||||
</data>
|
||||
<data name="Compare_Filter_Fg_Without" xml:space="preserve">
|
||||
<value>Without frame generation</value>
|
||||
</data>
|
||||
<data name="Compare_Count_Format" xml:space="preserve">
|
||||
<value>{0} sessions</value>
|
||||
</data>
|
||||
<data name="Compare_Count_Filtered_Format" xml:space="preserve">
|
||||
<value>{0} of {1} sessions</value>
|
||||
</data>
|
||||
<data name="Compare_ClearSelection" xml:space="preserve">
|
||||
<value>Clear selection</value>
|
||||
</data>
|
||||
<data name="Compare_MidSession_Changed" xml:space="preserve">
|
||||
<value>Changed mid-session</value>
|
||||
</data>
|
||||
<data name="Compare_Table_Header" xml:space="preserve">
|
||||
<value>Statistics</value>
|
||||
</data>
|
||||
@@ -1947,6 +2013,30 @@
|
||||
<data name="A11y_Games_Sort" xml:space="preserve">
|
||||
<value>Sort games</value>
|
||||
</data>
|
||||
<data name="A11y_Games_Filter_Store" xml:space="preserve">
|
||||
<value>Filter games by store</value>
|
||||
</data>
|
||||
<data name="A11y_Games_Filter_Engine" xml:space="preserve">
|
||||
<value>Filter games by engine</value>
|
||||
</data>
|
||||
<data name="A11y_Games_Filter_State" xml:space="preserve">
|
||||
<value>Filter games by state</value>
|
||||
</data>
|
||||
<data name="A11y_Games_Filter_Installed" xml:space="preserve">
|
||||
<value>Filter games by installed</value>
|
||||
</data>
|
||||
<data name="A11y_Games_Filter_Played" xml:space="preserve">
|
||||
<value>Filter games by sessions</value>
|
||||
</data>
|
||||
<data name="A11y_Compare_Filter_Game" xml:space="preserve">
|
||||
<value>Filter sessions by game</value>
|
||||
</data>
|
||||
<data name="A11y_Compare_Filter_Tier" xml:space="preserve">
|
||||
<value>Filter sessions by tier</value>
|
||||
</data>
|
||||
<data name="A11y_Compare_Filter_Fg" xml:space="preserve">
|
||||
<value>Filter sessions by frame generation</value>
|
||||
</data>
|
||||
<data name="A11y_Logs_Source" xml:space="preserve">
|
||||
<value>Log source</value>
|
||||
</data>
|
||||
|
||||
@@ -841,6 +841,39 @@
|
||||
<data name="Games_Sort_Label" xml:space="preserve">
|
||||
<value>Sắp xếp theo</value>
|
||||
</data>
|
||||
<data name="Games_Filter_Store_All" xml:space="preserve">
|
||||
<value>Mọi cửa hàng</value>
|
||||
</data>
|
||||
<data name="Games_Filter_Store_Manual" xml:space="preserve">
|
||||
<value>Thêm thủ công</value>
|
||||
</data>
|
||||
<data name="Games_Filter_Engine_All" xml:space="preserve">
|
||||
<value>Mọi engine</value>
|
||||
</data>
|
||||
<data name="Games_Filter_Engine_Unknown" xml:space="preserve">
|
||||
<value>Chưa nhận diện engine</value>
|
||||
</data>
|
||||
<data name="Games_Filter_State_All" xml:space="preserve">
|
||||
<value>Mọi trạng thái</value>
|
||||
</data>
|
||||
<data name="Games_Filter_Installed_All" xml:space="preserve">
|
||||
<value>Đã cài hoặc chưa</value>
|
||||
</data>
|
||||
<data name="Games_Filter_Installed_Yes" xml:space="preserve">
|
||||
<value>Đã cài</value>
|
||||
</data>
|
||||
<data name="Games_Filter_Played_All" xml:space="preserve">
|
||||
<value>Đã chơi hoặc chưa</value>
|
||||
</data>
|
||||
<data name="Games_Filter_Played_Yes" xml:space="preserve">
|
||||
<value>Có phiên</value>
|
||||
</data>
|
||||
<data name="Games_Header_Filtered_Format" xml:space="preserve">
|
||||
<value>Game · {0} / {1}</value>
|
||||
</data>
|
||||
<data name="Filter_Clear" xml:space="preserve">
|
||||
<value>Bỏ lọc</value>
|
||||
</data>
|
||||
<data name="Games_Sort_LastPlayed" xml:space="preserve">
|
||||
<value>Chơi gần nhất</value>
|
||||
</data>
|
||||
@@ -1207,6 +1240,39 @@
|
||||
<data name="Compare_Selected_Format" xml:space="preserve">
|
||||
<value>Đã chọn {0}</value>
|
||||
</data>
|
||||
<data name="Compare_Filter_Game_All" xml:space="preserve">
|
||||
<value>Mọi game</value>
|
||||
</data>
|
||||
<data name="Compare_Filter_Tier_All" xml:space="preserve">
|
||||
<value>Mọi tier</value>
|
||||
</data>
|
||||
<data name="Compare_Filter_Tier_Measured" xml:space="preserve">
|
||||
<value>Có đo (Tier 1)</value>
|
||||
</data>
|
||||
<data name="Compare_Filter_Tier_NotMeasured" xml:space="preserve">
|
||||
<value>Không đo (Tier 2)</value>
|
||||
</data>
|
||||
<data name="Compare_Filter_Fg_All" xml:space="preserve">
|
||||
<value>Có hoặc không tạo khung hình</value>
|
||||
</data>
|
||||
<data name="Compare_Filter_Fg_With" xml:space="preserve">
|
||||
<value>Có tạo khung hình</value>
|
||||
</data>
|
||||
<data name="Compare_Filter_Fg_Without" xml:space="preserve">
|
||||
<value>Không tạo khung hình</value>
|
||||
</data>
|
||||
<data name="Compare_Count_Format" xml:space="preserve">
|
||||
<value>{0} phiên</value>
|
||||
</data>
|
||||
<data name="Compare_Count_Filtered_Format" xml:space="preserve">
|
||||
<value>{0} / {1} phiên</value>
|
||||
</data>
|
||||
<data name="Compare_ClearSelection" xml:space="preserve">
|
||||
<value>Bỏ chọn</value>
|
||||
</data>
|
||||
<data name="Compare_MidSession_Changed" xml:space="preserve">
|
||||
<value>Đổi giữa phiên</value>
|
||||
</data>
|
||||
<data name="Compare_Table_Header" xml:space="preserve">
|
||||
<value>Thống kê</value>
|
||||
</data>
|
||||
@@ -1942,6 +2008,30 @@
|
||||
<data name="A11y_Games_Sort" xml:space="preserve">
|
||||
<value>Sắp xếp game</value>
|
||||
</data>
|
||||
<data name="A11y_Games_Filter_Store" xml:space="preserve">
|
||||
<value>Lọc game theo cửa hàng</value>
|
||||
</data>
|
||||
<data name="A11y_Games_Filter_Engine" xml:space="preserve">
|
||||
<value>Lọc game theo engine</value>
|
||||
</data>
|
||||
<data name="A11y_Games_Filter_State" xml:space="preserve">
|
||||
<value>Lọc game theo trạng thái</value>
|
||||
</data>
|
||||
<data name="A11y_Games_Filter_Installed" xml:space="preserve">
|
||||
<value>Lọc game theo tình trạng cài đặt</value>
|
||||
</data>
|
||||
<data name="A11y_Games_Filter_Played" xml:space="preserve">
|
||||
<value>Lọc game theo phiên</value>
|
||||
</data>
|
||||
<data name="A11y_Compare_Filter_Game" xml:space="preserve">
|
||||
<value>Lọc phiên theo game</value>
|
||||
</data>
|
||||
<data name="A11y_Compare_Filter_Tier" xml:space="preserve">
|
||||
<value>Lọc phiên theo tier</value>
|
||||
</data>
|
||||
<data name="A11y_Compare_Filter_Fg" xml:space="preserve">
|
||||
<value>Lọc phiên theo tạo khung hình</value>
|
||||
</data>
|
||||
<data name="A11y_Logs_Source" xml:space="preserve">
|
||||
<value>Nguồn log</value>
|
||||
</data>
|
||||
|
||||
@@ -11,6 +11,11 @@
|
||||
Our styles, merged LAST (16_WPFUI_SYNTAX §App bootstrap). Colours only through theme brushes with
|
||||
DynamicResource; the chart palette (16 §Theming) arrives with the charts (P3 PR-6) as its own dictionary.
|
||||
-->
|
||||
<ResourceDictionary.MergedDictionaries>
|
||||
<!-- beta.34: the pane item's sizes (FlLeftFluentNavigationViewItemTemplate, below), as WPF UI's own template reads them. -->
|
||||
<ResourceDictionary Source="pack://application:,,,/Wpf.Ui;component/Controls/NavigationView/NavigationViewConstants.xaml" />
|
||||
</ResourceDictionary.MergedDictionaries>
|
||||
|
||||
<BooleanToVisibilityConverter x:Key="BoolToVis" />
|
||||
<converters:InverseBoolToVisibilityConverter x:Key="InverseBoolToVis" />
|
||||
<converters:NullToCollapsedConverter x:Key="NullToCollapsed" />
|
||||
@@ -329,4 +334,113 @@
|
||||
</Setter.Value>
|
||||
</Setter>
|
||||
</Style>
|
||||
|
||||
<!--
|
||||
The navigation pane's item, beta.34 (owner request 2026-11-06, D86): WPF UI 4.3.0's LeftFluentNavigationViewItemTemplate
|
||||
(lepoco/wpfui, MIT - src/Wpf.Ui/Controls/NavigationView/NavigationLeftFluent.xaml at tag 4.3.0), copied with ONE
|
||||
change: its IsActive trigger animated the label's ContentGrid to height 0 and opacity 0, so the selected page lost its
|
||||
name - the owner's screenshot of Compare, and every other page the same while it was selected. The selected item keeps
|
||||
the accent bar, the selected background, the accent icon and the border animation. Set as RootNavigation.ItemTemplate
|
||||
(MainWindow.xaml): a local value outranks the default style's PaneDisplayMode=LeftFluent trigger.
|
||||
-->
|
||||
<ControlTemplate x:Key="FlLeftFluentNavigationViewItemTemplate" TargetType="{x:Type ui:NavigationViewItem}">
|
||||
<Border x:Name="MainBorder"
|
||||
MinWidth="{StaticResource PaneFluentButtonWidth}"
|
||||
Height="{StaticResource PaneFluentButtonHeight}"
|
||||
Padding="4"
|
||||
HorizontalAlignment="Stretch"
|
||||
Background="Transparent"
|
||||
BorderBrush="{TemplateBinding BorderBrush}"
|
||||
BorderThickness="1"
|
||||
CornerRadius="4">
|
||||
<Grid>
|
||||
<Rectangle x:Name="ActiveRectangle"
|
||||
Width="3"
|
||||
Height="24"
|
||||
Margin="-4,0,0,0"
|
||||
HorizontalAlignment="Left"
|
||||
VerticalAlignment="Center"
|
||||
Fill="{DynamicResource NavigationViewSelectionIndicatorForeground}"
|
||||
Opacity="0.0"
|
||||
RadiusX="2"
|
||||
RadiusY="2" />
|
||||
<Grid HorizontalAlignment="Stretch" VerticalAlignment="Stretch">
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="*" />
|
||||
<RowDefinition Height="Auto" />
|
||||
</Grid.RowDefinitions>
|
||||
<ContentPresenter x:Name="IconContentPresenter"
|
||||
Grid.Row="0"
|
||||
Margin="0"
|
||||
Content="{TemplateBinding Icon}"
|
||||
TextElement.FontSize="{StaticResource NavigationViewFluentIconSize}"
|
||||
TextElement.Foreground="{DynamicResource NavigationViewItemForegroundLeftFluent}" />
|
||||
<Grid x:Name="ContentGrid"
|
||||
Grid.Row="1"
|
||||
Height="{StaticResource NavigationViewFluentIconSize}"
|
||||
Margin="0,2,0,0">
|
||||
<ContentPresenter x:Name="ElementContentPresenter"
|
||||
HorizontalAlignment="Center"
|
||||
Content="{TemplateBinding Content}"
|
||||
ContentTemplate="{TemplateBinding ContentTemplate}"
|
||||
RecognizesAccessKey="True"
|
||||
TextElement.FontSize="{TemplateBinding FontSize}"
|
||||
TextElement.Foreground="{DynamicResource NavigationViewItemForegroundLeftFluent}" />
|
||||
</Grid>
|
||||
<ContentPresenter x:Name="PART_InfoBadge"
|
||||
Grid.Row="0"
|
||||
Margin="0"
|
||||
HorizontalAlignment="Right"
|
||||
VerticalAlignment="Top"
|
||||
Content="{TemplateBinding InfoBadge}" />
|
||||
</Grid>
|
||||
</Grid>
|
||||
</Border>
|
||||
<ControlTemplate.Triggers>
|
||||
<Trigger Property="IsActive" Value="True">
|
||||
<Setter TargetName="ActiveRectangle" Property="Opacity" Value="1.0" />
|
||||
<Setter TargetName="MainBorder" Property="Background" Value="{DynamicResource NavigationViewItemBackgroundSelectedLeftFluent}" />
|
||||
<Setter TargetName="IconContentPresenter" Property="TextElement.Foreground" Value="{DynamicResource NavigationViewSelectionIndicatorForeground}" />
|
||||
<Setter TargetName="ElementContentPresenter" Property="Margin" Value="0" />
|
||||
<Trigger.EnterActions>
|
||||
<BeginStoryboard>
|
||||
<Storyboard>
|
||||
<DoubleAnimation Storyboard.TargetName="MainBorder"
|
||||
Storyboard.TargetProperty="(Border.BorderBrush).(SolidColorBrush.Opacity)"
|
||||
From="0" To="1" Duration="0:0:.16" />
|
||||
</Storyboard>
|
||||
</BeginStoryboard>
|
||||
</Trigger.EnterActions>
|
||||
<Trigger.ExitActions>
|
||||
<BeginStoryboard>
|
||||
<Storyboard>
|
||||
<DoubleAnimation Storyboard.TargetName="MainBorder"
|
||||
Storyboard.TargetProperty="(Border.BorderBrush).(SolidColorBrush.Opacity)"
|
||||
From="1" To="0" Duration="0:0:.16" />
|
||||
</Storyboard>
|
||||
</BeginStoryboard>
|
||||
</Trigger.ExitActions>
|
||||
</Trigger>
|
||||
<Trigger Property="Icon" Value="{x:Null}">
|
||||
<Setter TargetName="IconContentPresenter" Property="Visibility" Value="Collapsed" />
|
||||
</Trigger>
|
||||
<Trigger Property="InfoBadge" Value="{x:Null}">
|
||||
<Setter TargetName="PART_InfoBadge" Property="Margin" Value="0" />
|
||||
<Setter TargetName="PART_InfoBadge" Property="Visibility" Value="Collapsed" />
|
||||
</Trigger>
|
||||
<Trigger Property="IsMouseOver" Value="True">
|
||||
<Setter TargetName="MainBorder" Property="Background" Value="{DynamicResource NavigationViewItemBackgroundSelectedLeftFluent}" />
|
||||
</Trigger>
|
||||
<MultiTrigger>
|
||||
<MultiTrigger.Conditions>
|
||||
<Condition Property="IsMouseOver" Value="True" />
|
||||
<Condition Property="IsActive" Value="False" />
|
||||
</MultiTrigger.Conditions>
|
||||
<MultiTrigger.Setters>
|
||||
<Setter TargetName="IconContentPresenter" Property="TextElement.Foreground" Value="{DynamicResource NavigationViewItemForegroundPointerOverLeftFluent}" />
|
||||
<Setter TargetName="ContentGrid" Property="TextElement.Foreground" Value="{DynamicResource NavigationViewItemForegroundPointerOverLeftFluent}" />
|
||||
</MultiTrigger.Setters>
|
||||
</MultiTrigger>
|
||||
</ControlTemplate.Triggers>
|
||||
</ControlTemplate>
|
||||
</ResourceDictionary>
|
||||
@@ -18,18 +18,38 @@ public sealed partial class CompareCandidateViewModel : ObservableObject
|
||||
ArgumentNullException.ThrowIfNull(recent);
|
||||
Row = recent.Row;
|
||||
Id = recent.Row.Id;
|
||||
GameId = recent.Row.GameId;
|
||||
StartedAt = recent.Row.StartedAt;
|
||||
GameName = recent.GameName;
|
||||
DateText = Formats.Date(recent.Row.StartedAt);
|
||||
IsHooked = recent.Row.Tier == CaptureTier.Hooked;
|
||||
TierText = IsHooked ? Strings.Tier_Hooked : Strings.Tier_NotHooked;
|
||||
ReadoutLine = FpsPresentation.FromRow(recent.Row).Line;
|
||||
SettingsChangedMidSession = recent.Row.SettingsChangedMidSession;
|
||||
SettingsChangedText = SettingsChangedMidSession ? Strings.Compare_MidSession_Changed : "—";
|
||||
HasFrameGeneration = recent.Row.FgMode switch
|
||||
{
|
||||
"none" => false,
|
||||
"na" or null => null,
|
||||
_ => true,
|
||||
};
|
||||
}
|
||||
|
||||
public Application.Persistence.SessionRow Row { get; }
|
||||
|
||||
public long Id { get; }
|
||||
|
||||
public long GameId { get; }
|
||||
|
||||
/// <summary>The date column sorts by this, not by its text (beta.34).</summary>
|
||||
public DateTimeOffset StartedAt { get; }
|
||||
|
||||
/// <summary>beta.34 (D85): frame generation in the session — true, false (measured none), or null (not measured: Tier 2).</summary>
|
||||
public bool? HasFrameGeneration { get; }
|
||||
|
||||
/// <summary>The Settings-changed cell's words beside its icon, or a dash — the column was blank for every unchanged session.</summary>
|
||||
public string SettingsChangedText { get; }
|
||||
|
||||
public string GameName { get; }
|
||||
|
||||
public string DateText { get; }
|
||||
|
||||
@@ -0,0 +1,12 @@
|
||||
// SPDX-License-Identifier: GPL-3.0-only
|
||||
// Copyright (C) 2026 poli0981 - additional terms under GPLv3 section 7: see NOTICE
|
||||
|
||||
namespace FrameLedger.App.ViewModels;
|
||||
|
||||
/// <summary>Compare's tier filter (beta.34, D85): every session, the measured (Tier 1), or those recorded without measurement.</summary>
|
||||
public enum CompareTierFilter
|
||||
{
|
||||
All = 0,
|
||||
Measured,
|
||||
NotMeasured,
|
||||
}
|
||||
@@ -51,6 +51,21 @@ public sealed partial class CompareViewModel : ObservableObject
|
||||
[ObservableProperty]
|
||||
private string? _tierLegend;
|
||||
|
||||
/// <summary>beta.34 (D85): one game's sessions, or 0 for every game's.</summary>
|
||||
[ObservableProperty]
|
||||
private long _gameFilter;
|
||||
|
||||
[ObservableProperty]
|
||||
private CompareTierFilter _tierFilter;
|
||||
|
||||
[ObservableProperty]
|
||||
private YesNoFilter _frameGenerationFilter;
|
||||
|
||||
[ObservableProperty]
|
||||
private string _countText = string.Empty;
|
||||
|
||||
private List<CompareCandidateViewModel> _pool = [];
|
||||
|
||||
public CompareViewModel(GameLibrary library, SessionSeriesLoader loader, IMixedTierPrompt mixed, IFileSaver saver, IMessageStrip strip)
|
||||
{
|
||||
_library = library ?? throw new ArgumentNullException(nameof(library));
|
||||
@@ -77,6 +92,27 @@ public sealed partial class CompareViewModel : ObservableObject
|
||||
|
||||
public static string MetricHeader => Strings.Compare_Table_Metric;
|
||||
|
||||
public static string ClearFiltersText => Strings.Filter_Clear;
|
||||
|
||||
public static string ClearSelectionText => Strings.Compare_ClearSelection;
|
||||
|
||||
/// <summary>beta.34 (D85): the games the sessions are of, "All games" first.</summary>
|
||||
public ObservableCollection<Choice<long>> Games { get; } = [];
|
||||
|
||||
public IReadOnlyList<Choice<CompareTierFilter>> Tiers { get; } =
|
||||
[
|
||||
new(CompareTierFilter.All, Strings.Compare_Filter_Tier_All),
|
||||
new(CompareTierFilter.Measured, Strings.Compare_Filter_Tier_Measured),
|
||||
new(CompareTierFilter.NotMeasured, Strings.Compare_Filter_Tier_NotMeasured),
|
||||
];
|
||||
|
||||
public IReadOnlyList<Choice<YesNoFilter>> FrameGenerationChoices { get; } =
|
||||
[
|
||||
new(YesNoFilter.All, Strings.Compare_Filter_Fg_All),
|
||||
new(YesNoFilter.Yes, Strings.Compare_Filter_Fg_With),
|
||||
new(YesNoFilter.No, Strings.Compare_Filter_Fg_Without),
|
||||
];
|
||||
|
||||
public ObservableCollection<CompareCandidateViewModel> Candidates { get; } = [];
|
||||
|
||||
public ObservableCollection<CompareCandidateViewModel> Compared { get; } = [];
|
||||
@@ -93,26 +129,97 @@ public sealed partial class CompareViewModel : ObservableObject
|
||||
/// <summary>Raised when <see cref="Curves"/> and <see cref="Rows"/> were rebuilt, so the page redraws.</summary>
|
||||
public event EventHandler? Compared2;
|
||||
|
||||
/// <summary>
|
||||
/// Every session, newest first (beta.34: it was the newest 200), read on the thread pool — Microsoft.Data.Sqlite completes
|
||||
/// its asynchronous calls synchronously, and the page waited for it — and then filtered (D85).
|
||||
/// </summary>
|
||||
public async Task LoadAsync(CancellationToken ct = default)
|
||||
{
|
||||
IReadOnlyList<RecentSession> recent = await _library.RecentAsync(200, ct).ConfigureAwait(true);
|
||||
foreach (CompareCandidateViewModel old in Candidates)
|
||||
GameLibrary library = _library;
|
||||
IReadOnlyList<RecentSession> recent = await Task.Run(() => library.RecentAsync(int.MaxValue, ct), ct).ConfigureAwait(true);
|
||||
foreach (CompareCandidateViewModel old in _pool)
|
||||
{
|
||||
old.PropertyChanged -= OnCandidateChanged;
|
||||
}
|
||||
|
||||
Candidates.Clear();
|
||||
var pool = new List<CompareCandidateViewModel>(recent.Count);
|
||||
foreach (RecentSession r in recent)
|
||||
{
|
||||
var candidate = new CompareCandidateViewModel(r);
|
||||
candidate.PropertyChanged += OnCandidateChanged;
|
||||
Candidates.Add(candidate);
|
||||
pool.Add(candidate);
|
||||
}
|
||||
|
||||
IsEmpty = Candidates.Count == 0;
|
||||
_pool = pool;
|
||||
Choice<long>[] games =
|
||||
[
|
||||
new(0, Strings.Compare_Filter_Game_All),
|
||||
.. pool.GroupBy(static c => c.GameId).Select(static g => new Choice<long>(g.Key, g.First().GameName))
|
||||
.OrderBy(static c => c.Label, StringComparer.CurrentCultureIgnoreCase),
|
||||
];
|
||||
Games.Clear();
|
||||
foreach (Choice<long> game in games)
|
||||
{
|
||||
Games.Add(game);
|
||||
}
|
||||
|
||||
if (!Games.Any(g => g.Value == GameFilter))
|
||||
{
|
||||
GameFilter = 0;
|
||||
}
|
||||
|
||||
IsEmpty = _pool.Count == 0;
|
||||
ApplyFilters();
|
||||
Recount();
|
||||
}
|
||||
|
||||
partial void OnGameFilterChanged(long value) => ApplyFilters();
|
||||
|
||||
partial void OnTierFilterChanged(CompareTierFilter value) => ApplyFilters();
|
||||
|
||||
partial void OnFrameGenerationFilterChanged(YesNoFilter value) => ApplyFilters();
|
||||
|
||||
[RelayCommand]
|
||||
private void ClearFilters()
|
||||
{
|
||||
GameFilter = 0;
|
||||
TierFilter = CompareTierFilter.All;
|
||||
FrameGenerationFilter = YesNoFilter.All;
|
||||
}
|
||||
|
||||
[RelayCommand]
|
||||
private void ClearSelection()
|
||||
{
|
||||
foreach (CompareCandidateViewModel c in _pool.Where(static c => c.IsSelected))
|
||||
{
|
||||
c.IsSelected = false;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// The list the filters leave (beta.34, D85), newest first — and every ticked session whatever they say: a pick is never
|
||||
/// hidden from the one who made it, so what Compare runs on is always on screen.
|
||||
/// </summary>
|
||||
private void ApplyFilters()
|
||||
{
|
||||
CompareCandidateViewModel[] shown = [.. _pool.Where(c => c.IsSelected || Passes(c))];
|
||||
Candidates.Clear();
|
||||
foreach (CompareCandidateViewModel c in shown)
|
||||
{
|
||||
Candidates.Add(c);
|
||||
}
|
||||
|
||||
bool filtered = GameFilter != 0 || TierFilter != CompareTierFilter.All || FrameGenerationFilter != YesNoFilter.All;
|
||||
CountText = filtered
|
||||
? string.Format(CultureInfo.CurrentCulture, Strings.Compare_Count_Filtered_Format, shown.Length, _pool.Count)
|
||||
: string.Format(CultureInfo.CurrentCulture, Strings.Compare_Count_Format, _pool.Count);
|
||||
}
|
||||
|
||||
private bool Passes(CompareCandidateViewModel c) =>
|
||||
(GameFilter == 0 || c.GameId == GameFilter)
|
||||
&& TierFilter switch { CompareTierFilter.Measured => c.IsHooked, CompareTierFilter.NotMeasured => !c.IsHooked, _ => true }
|
||||
&& FrameGenerationFilter switch { YesNoFilter.Yes => c.HasFrameGeneration is true, YesNoFilter.No => c.HasFrameGeneration is false, _ => true };
|
||||
|
||||
[RelayCommand]
|
||||
private Task CompareAsync() => Run(CompareCoreAsync);
|
||||
|
||||
@@ -141,7 +248,7 @@ public sealed partial class CompareViewModel : ObservableObject
|
||||
|
||||
private async Task CompareCoreAsync()
|
||||
{
|
||||
CompareCandidateViewModel[] picked = [.. Candidates.Where(static c => c.IsSelected)];
|
||||
CompareCandidateViewModel[] picked = [.. _pool.Where(static c => c.IsSelected)];
|
||||
if (picked.Length < MinSessions || picked.Length > MaxSessions)
|
||||
{
|
||||
return;
|
||||
@@ -284,7 +391,7 @@ public sealed partial class CompareViewModel : ObservableObject
|
||||
|
||||
private void Recount()
|
||||
{
|
||||
SelectedCount = Candidates.Count(static c => c.IsSelected);
|
||||
SelectedCount = _pool.Count(static c => c.IsSelected);
|
||||
CanCompare = SelectedCount is >= MinSessions and <= MaxSessions;
|
||||
OnPropertyChanged(nameof(SelectedText));
|
||||
}
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
|
||||
using System.Diagnostics.CodeAnalysis;
|
||||
using System.Globalization;
|
||||
using CommunityToolkit.Mvvm.ComponentModel;
|
||||
using FrameLedger.App.Services;
|
||||
|
||||
namespace FrameLedger.App.ViewModels;
|
||||
@@ -12,19 +13,32 @@ namespace FrameLedger.App.ViewModels;
|
||||
/// playtime, last played, hooking state — or, since 2026-09-23, "Not recorded" in its place for an entry whose recording is
|
||||
/// off, and since 2026-09-25 "Anti-cheat" for one the guard found anti-cheat in; since beta.11 "Not installed" beside it
|
||||
/// when its executable is not on disk (<see cref="GameLibrary.ExecutableExists"/>, read when the library is listed, never
|
||||
/// stored), with the game page's own words for why (<see cref="Formats.ExecutableMissingText"/>).
|
||||
/// stored), with the game page's own words for why (<see cref="Formats.ExecutableMissingText"/>). Since beta.34 a card is
|
||||
/// shown before its executable is checked and gets the pill when the check answers (<see cref="SetInstalled"/>): a drive
|
||||
/// that sleeps took a second to say, and no card appeared until every one had.
|
||||
/// </summary>
|
||||
[SuppressMessage("Performance", "CA1863:Use 'CompositeFormat'", Justification = "the format strings are resources that follow the UI culture, which changes at runtime")]
|
||||
public sealed class GameCardViewModel
|
||||
public sealed partial class GameCardViewModel : ObservableObject
|
||||
{
|
||||
/// <summary>beta.11: the "Not installed" pill shows — the file, or the drive it was on, is not there now.</summary>
|
||||
[ObservableProperty]
|
||||
[NotifyPropertyChangedFor(nameof(StatusText))]
|
||||
private bool _notInstalled;
|
||||
|
||||
/// <summary>What the pill means here — the drive that is not connected, or the path the file is gone from; null when installed.</summary>
|
||||
[ObservableProperty]
|
||||
private string? _notInstalledToolTip;
|
||||
|
||||
public GameCardViewModel(GameCard card, bool installed = true)
|
||||
{
|
||||
ArgumentNullException.ThrowIfNull(card);
|
||||
Card = card;
|
||||
NotInstalled = !installed;
|
||||
NotInstalledToolTip = installed ? null : Formats.ExecutableMissingText(card.Row.Fingerprint.ExePath);
|
||||
_notInstalled = !installed;
|
||||
_notInstalledToolTip = installed ? null : Formats.ExecutableMissingText(card.Row.Fingerprint.ExePath);
|
||||
Id = card.Row.Id;
|
||||
Name = card.Row.Name;
|
||||
PlatformToken = card.Row.Platform;
|
||||
EngineToken = card.Row.Engine;
|
||||
PlatformText = Formats.Platform(card.Row.Platform);
|
||||
EngineText = Formats.Engine(card.Row.Engine, card.Row.EngineVersionSource);
|
||||
Recorded = card.Row.RecordSessions;
|
||||
@@ -59,6 +73,18 @@ public sealed class GameCardViewModel
|
||||
|
||||
public string PlatformText { get; }
|
||||
|
||||
/// <summary>The store's token (<c>steam</c>, <c>gog</c>, <c>epic</c>, <c>itch</c>, <c>xbox</c>; <c>none</c> for a game added by hand) — the store filter's key.</summary>
|
||||
public string PlatformToken { get; }
|
||||
|
||||
/// <summary>The detected engine's id, or null — the engine filter's key.</summary>
|
||||
public string? EngineToken { get; }
|
||||
|
||||
/// <summary>The card's one state, as its pill says it (beta.34, D85).</summary>
|
||||
public GamesStateFilter State => !Recorded ? GamesStateFilter.NotRecorded
|
||||
: Excepted ? GamesStateFilter.Exception
|
||||
: AntiCheat ? GamesStateFilter.AntiCheat
|
||||
: HookOn ? GamesStateFilter.HookingOn : GamesStateFilter.HookingOff;
|
||||
|
||||
public bool HasPlatform => PlatformText.Length > 0;
|
||||
|
||||
public string EngineText { get; }
|
||||
@@ -99,12 +125,33 @@ public sealed class GameCardViewModel
|
||||
/// <summary>The list view's last-played cell: the date alone, or "not played yet".</summary>
|
||||
public string LastPlayedValue { get; }
|
||||
|
||||
/// <summary>beta.11: the "Not installed" pill shows — the file, or the drive it was on, is not there now.</summary>
|
||||
public bool NotInstalled { get; }
|
||||
|
||||
/// <summary>What the pill means here — the drive that is not connected, or the path the file is gone from; null when installed.</summary>
|
||||
public string? NotInstalledToolTip { get; }
|
||||
|
||||
/// <summary>The list view's status cell: what the hook pill says, and "Not installed" after it when that is so.</summary>
|
||||
public string StatusText => NotInstalled ? HookText + " · " + Strings.Games_Card_NotInstalled : HookText;
|
||||
|
||||
/// <summary>The executable check's answer, when it comes (beta.34) — with the reason, read off the UI thread with it.</summary>
|
||||
public void SetInstalled(bool installed, string? whyNot)
|
||||
{
|
||||
NotInstalled = !installed;
|
||||
NotInstalledToolTip = installed ? null : whyNot;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Whether <paramref name="other"/> — the same game read again — would look the same on its card and in its row, and
|
||||
/// play the same executable (beta.34): a reload keeps the card it already has, and rebuilds only one that changed.
|
||||
/// </summary>
|
||||
public bool LooksLike(GameCardViewModel other)
|
||||
{
|
||||
ArgumentNullException.ThrowIfNull(other);
|
||||
return Id == other.Id
|
||||
&& string.Equals(Name, other.Name, StringComparison.Ordinal)
|
||||
&& string.Equals(PlatformText, other.PlatformText, StringComparison.Ordinal)
|
||||
&& string.Equals(EngineText, other.EngineText, StringComparison.Ordinal)
|
||||
&& string.Equals(HookText, other.HookText, StringComparison.Ordinal)
|
||||
&& string.Equals(SessionsText, other.SessionsText, StringComparison.Ordinal)
|
||||
&& string.Equals(PlaytimeText, other.PlaytimeText, StringComparison.Ordinal)
|
||||
&& string.Equals(LastPlayedText, other.LastPlayedText, StringComparison.Ordinal)
|
||||
&& string.Equals(Card.Row.Fingerprint.ExePath, other.Card.Row.Fingerprint.ExePath, StringComparison.OrdinalIgnoreCase)
|
||||
&& string.Equals(Card.Row.Platform, other.Card.Row.Platform, StringComparison.Ordinal)
|
||||
&& string.Equals(Card.Row.StoreId, other.Card.Row.StoreId, StringComparison.Ordinal);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,15 @@
|
||||
// SPDX-License-Identifier: GPL-3.0-only
|
||||
// Copyright (C) 2026 poli0981 - additional terms under GPLv3 section 7: see NOTICE
|
||||
|
||||
namespace FrameLedger.App.ViewModels;
|
||||
|
||||
/// <summary>The library's state filter (beta.34, D85): the card's one state, as its pill says it.</summary>
|
||||
public enum GamesStateFilter
|
||||
{
|
||||
All = 0,
|
||||
HookingOn,
|
||||
HookingOff,
|
||||
AntiCheat,
|
||||
Exception,
|
||||
NotRecorded,
|
||||
}
|
||||
@@ -17,7 +17,10 @@ namespace FrameLedger.App.ViewModels;
|
||||
/// open by click. Since beta.11 (owner requests 2026-10-03): shown as a grid of cards that fills the width or as a list
|
||||
/// (<c>ui.library_view</c>), with the count in the header; <b>Refresh</b> reloads the library, looks in the stores for games
|
||||
/// installed since and offers only those, and marks entries whose executable is gone ("Not installed"); and the page
|
||||
/// reloads by itself when a session ends or an import adds games while it is on screen.
|
||||
/// reloads by itself when a session ends or an import adds games while it is on screen. Since beta.34 (owner request
|
||||
/// 2026-11-06, "Games stalls 0.5–1.5 s"; <c>spike-notes</c> §27) the page is kept by its window (<see cref="WindowPageCache"/>)
|
||||
/// and reads the library again each time it is shown; the library is read on the thread pool, the cards appear before
|
||||
/// the executables are checked, and a read keeps every card that would look the same.
|
||||
/// </summary>
|
||||
[System.Diagnostics.CodeAnalysis.SuppressMessage("Performance", "CA1863:Use 'CompositeFormat'", Justification = "the format strings are resources that follow the UI culture, which changes at runtime")]
|
||||
public sealed partial class GamesViewModel : ObservableObject
|
||||
@@ -25,6 +28,12 @@ public sealed partial class GamesViewModel : ObservableObject
|
||||
private const string _listValue = "list";
|
||||
private const string _gridValue = "grid";
|
||||
|
||||
/// <summary>The store and engine filters' "everything" (beta.34, D85); no store or engine token is empty.</summary>
|
||||
public const string AnyToken = "";
|
||||
|
||||
/// <summary>The engine filter's "not identified".</summary>
|
||||
public const string UnknownEngineToken = "?";
|
||||
|
||||
/// <summary>How many removed games one notice names; the rest are counted (<c>Games_Removed_More_Format</c>).</summary>
|
||||
private const int _removedNamed = 5;
|
||||
|
||||
@@ -43,10 +52,11 @@ public sealed partial class GamesViewModel : ObservableObject
|
||||
private readonly Func<string, bool> _exists;
|
||||
private readonly UiThread _ui = new();
|
||||
private readonly List<string> _removed = [];
|
||||
private IReadOnlyList<GameCardViewModel> _all = [];
|
||||
private List<GameCardViewModel> _all = [];
|
||||
private int _reads;
|
||||
private bool _viewRead;
|
||||
private bool _attached;
|
||||
private bool _shownBefore;
|
||||
|
||||
[ObservableProperty]
|
||||
private string _search = string.Empty;
|
||||
@@ -67,6 +77,27 @@ public sealed partial class GamesViewModel : ObservableObject
|
||||
[ObservableProperty]
|
||||
private bool _listView;
|
||||
|
||||
/// <summary>beta.34 (D85): the store filter — a store token, or <see cref="AnyToken"/>.</summary>
|
||||
[ObservableProperty]
|
||||
private string _storeFilter = AnyToken;
|
||||
|
||||
/// <summary>beta.34 (D85): the engine filter — an engine id, <see cref="UnknownEngineToken"/>, or <see cref="AnyToken"/>.</summary>
|
||||
[ObservableProperty]
|
||||
private string _engineFilter = AnyToken;
|
||||
|
||||
[ObservableProperty]
|
||||
private GamesStateFilter _stateFilter;
|
||||
|
||||
[ObservableProperty]
|
||||
private YesNoFilter _installedFilter;
|
||||
|
||||
[ObservableProperty]
|
||||
private YesNoFilter _playedFilter;
|
||||
|
||||
/// <summary>A filter or the search narrows the list; the header then counts what is shown of all.</summary>
|
||||
[ObservableProperty]
|
||||
private bool _isFiltered;
|
||||
|
||||
/// <summary>What Play will do, in the mode Settings ▸ Games has now (beta.21, D59).</summary>
|
||||
[ObservableProperty]
|
||||
private string _playToolTip = Strings.Play_ToolTip_Store;
|
||||
@@ -128,6 +159,39 @@ public sealed partial class GamesViewModel : ObservableObject
|
||||
|
||||
public ObservableCollection<GameCardViewModel> Games { get; } = [];
|
||||
|
||||
/// <summary>beta.34 (D85): the stores the library holds, "All stores" first — rebuilt when the library changes them.</summary>
|
||||
public ObservableCollection<Choice<string>> Stores { get; } = [];
|
||||
|
||||
/// <summary>beta.34 (D85): the engines the library holds, "All engines" first, "Engine not identified" last when any is.</summary>
|
||||
public ObservableCollection<Choice<string>> Engines { get; } = [];
|
||||
|
||||
/// <summary>The states, labelled in the language the page opened in, as the pills say them.</summary>
|
||||
public IReadOnlyList<Choice<GamesStateFilter>> States { get; } =
|
||||
[
|
||||
new(GamesStateFilter.All, Strings.Games_Filter_State_All),
|
||||
new(GamesStateFilter.HookingOn, Strings.Games_Card_HookOn),
|
||||
new(GamesStateFilter.HookingOff, Strings.Games_Card_HookOff),
|
||||
new(GamesStateFilter.AntiCheat, Strings.Games_Card_AntiCheat),
|
||||
new(GamesStateFilter.Exception, Strings.Games_Card_Exception),
|
||||
new(GamesStateFilter.NotRecorded, Strings.Games_Card_NotRecorded),
|
||||
];
|
||||
|
||||
public IReadOnlyList<Choice<YesNoFilter>> InstalledChoices { get; } =
|
||||
[
|
||||
new(YesNoFilter.All, Strings.Games_Filter_Installed_All),
|
||||
new(YesNoFilter.Yes, Strings.Games_Filter_Installed_Yes),
|
||||
new(YesNoFilter.No, Strings.Games_Card_NotInstalled),
|
||||
];
|
||||
|
||||
public IReadOnlyList<Choice<YesNoFilter>> PlayedChoices { get; } =
|
||||
[
|
||||
new(YesNoFilter.All, Strings.Games_Filter_Played_All),
|
||||
new(YesNoFilter.Yes, Strings.Games_Filter_Played_Yes),
|
||||
new(YesNoFilter.No, Strings.Games_Card_NeverPlayed),
|
||||
];
|
||||
|
||||
public static string ClearFiltersText => Strings.Filter_Clear;
|
||||
|
||||
/// <summary>The load in flight, for a test to await.</summary>
|
||||
public Task Pending { get; private set; }
|
||||
|
||||
@@ -145,20 +209,73 @@ public sealed partial class GamesViewModel : ObservableObject
|
||||
PlayToolTip = await _player.IsDirectAsync(ct).ConfigureAwait(true) ? Strings.Play_ToolTip_Direct : Strings.Play_ToolTip_Store;
|
||||
}
|
||||
|
||||
IReadOnlyList<GameCard> cards = await _library.ListCardsAsync(ct).ConfigureAwait(true);
|
||||
// Whether each executable is on disk is a file-system question per entry — a drive that is gone can take a moment
|
||||
// to say so — so it is asked off the UI thread, the game page's own way (GameLibrary.ExecutableExists).
|
||||
Func<string, bool> exists = _exists;
|
||||
bool[] installed = await Task.Run(() => cards.Select(c => exists(c.Row.Fingerprint.ExePath)).ToArray(), ct)
|
||||
.ConfigureAwait(true);
|
||||
// beta.34: the library on the thread pool — Microsoft.Data.Sqlite completes its asynchronous calls synchronously,
|
||||
// so on the UI thread the read was the page's to wait for.
|
||||
GameLibrary library = _library;
|
||||
IReadOnlyList<GameCard> cards = await Task.Run(() => library.ListCardsAsync(ct), ct).ConfigureAwait(true);
|
||||
if (read != Volatile.Read(ref _reads))
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
_all = [.. cards.Select((c, i) => new GameCardViewModel(c, installed[i]))];
|
||||
HeaderText = string.Format(CultureInfo.CurrentCulture, Strings.Games_Header_Count_Format, _all.Count);
|
||||
// The cards first — each as the card it was, where it would look the same — and only then whether each executable
|
||||
// is on disk: a file-system question per entry that a sleeping drive answers in a second or more (39 of the owner's
|
||||
// 41 Steam games are on a USB drive), and no card was shown until every one had answered (spike-notes §27).
|
||||
_all = Merge(_all, cards);
|
||||
RefreshChoices();
|
||||
Apply();
|
||||
|
||||
Func<string, bool> exists = _exists;
|
||||
(bool Installed, string? WhyNot)[] checks = await Task.Run(() => cards.Select(c =>
|
||||
{
|
||||
string path = c.Row.Fingerprint.ExePath;
|
||||
bool installed = exists(path);
|
||||
return (installed, installed ? null : Formats.ExecutableMissingText(path));
|
||||
}).ToArray(), ct).ConfigureAwait(true);
|
||||
if (read != Volatile.Read(ref _reads))
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
var byId = _all.ToDictionary(static c => c.Id);
|
||||
for (int i = 0; i < cards.Count; i++)
|
||||
{
|
||||
if (byId.TryGetValue(cards[i].Row.Id, out GameCardViewModel? card))
|
||||
{
|
||||
card.SetInstalled(checks[i].Installed, checks[i].WhyNot);
|
||||
}
|
||||
}
|
||||
|
||||
Apply();
|
||||
PlayCommand.NotifyCanExecuteChanged();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// The library read again, as cards: an entry that would look the same keeps the card it has — its place on screen and
|
||||
/// its installed state until the check answers again — and only an entry that changed, or is new, gets a new one.
|
||||
/// </summary>
|
||||
private static List<GameCardViewModel> Merge(IReadOnlyList<GameCardViewModel> shown, IReadOnlyList<GameCard> cards)
|
||||
{
|
||||
var old = shown.ToDictionary(static c => c.Id);
|
||||
var merged = new List<GameCardViewModel>(cards.Count);
|
||||
foreach (GameCard card in cards)
|
||||
{
|
||||
var fresh = new GameCardViewModel(card);
|
||||
if (old.TryGetValue(card.Row.Id, out GameCardViewModel? kept))
|
||||
{
|
||||
if (kept.LooksLike(fresh))
|
||||
{
|
||||
merged.Add(kept);
|
||||
continue;
|
||||
}
|
||||
|
||||
fresh.SetInstalled(!kept.NotInstalled, kept.NotInstalledToolTip);
|
||||
}
|
||||
|
||||
merged.Add(fresh);
|
||||
}
|
||||
|
||||
return merged;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
@@ -184,6 +301,16 @@ public sealed partial class GamesViewModel : ObservableObject
|
||||
}
|
||||
|
||||
_attached = true;
|
||||
|
||||
// beta.34: the page is kept by its window and shown again on a later visit (WindowPageCache), so what happened while
|
||||
// it was away — a session that ended, a game removed, renamed or added on another page — is read now, behind the
|
||||
// cards already on screen. Its first Loaded follows the constructor's own read.
|
||||
if (_shownBefore)
|
||||
{
|
||||
Pending = LoadAsync();
|
||||
}
|
||||
|
||||
_shownBefore = true;
|
||||
}
|
||||
|
||||
public void Detach()
|
||||
@@ -281,6 +408,82 @@ public sealed partial class GamesViewModel : ObservableObject
|
||||
|
||||
partial void OnSortChanged(GamesSort value) => Apply();
|
||||
|
||||
partial void OnStoreFilterChanged(string value) => Apply();
|
||||
|
||||
partial void OnEngineFilterChanged(string value) => Apply();
|
||||
|
||||
partial void OnStateFilterChanged(GamesStateFilter value) => Apply();
|
||||
|
||||
partial void OnInstalledFilterChanged(YesNoFilter value) => Apply();
|
||||
|
||||
partial void OnPlayedFilterChanged(YesNoFilter value) => Apply();
|
||||
|
||||
/// <summary>beta.34 (D85): every filter back to everything; the search stays (it has its own box).</summary>
|
||||
[RelayCommand]
|
||||
private void ClearFilters()
|
||||
{
|
||||
StoreFilter = AnyToken;
|
||||
EngineFilter = AnyToken;
|
||||
StateFilter = GamesStateFilter.All;
|
||||
InstalledFilter = YesNoFilter.All;
|
||||
PlayedFilter = YesNoFilter.All;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// The store and engine choices from what the library holds — rebuilt only when that set changes, so an open list does not
|
||||
/// lose its selection on every read. A filter whose store or engine left the library goes back to everything.
|
||||
/// </summary>
|
||||
private void RefreshChoices()
|
||||
{
|
||||
Choice<string>[] stores =
|
||||
[
|
||||
new(AnyToken, Strings.Games_Filter_Store_All),
|
||||
.. _all.Select(static c => c.PlatformToken).Distinct(StringComparer.Ordinal)
|
||||
.Select(static t => new Choice<string>(t, Formats.Platform(t) is { Length: > 0 } name ? name : Strings.Games_Filter_Store_Manual))
|
||||
.OrderBy(static c => c.Label, StringComparer.CurrentCultureIgnoreCase),
|
||||
];
|
||||
Choice<string>[] engines =
|
||||
[
|
||||
new(AnyToken, Strings.Games_Filter_Engine_All),
|
||||
.. _all.Select(static c => c.EngineToken).OfType<string>().Distinct(StringComparer.Ordinal)
|
||||
.Select(static t => new Choice<string>(t, Formats.Engine(t) is { Length: > 0 } name ? name : t))
|
||||
.OrderBy(static c => c.Label, StringComparer.CurrentCultureIgnoreCase),
|
||||
.. _all.Any(static c => c.EngineToken is null) ? new[] { new Choice<string>(UnknownEngineToken, Strings.Games_Filter_Engine_Unknown) } : Array.Empty<Choice<string>>(),
|
||||
];
|
||||
Replace(Stores, stores);
|
||||
Replace(Engines, engines);
|
||||
if (!Stores.Any(c => string.Equals(c.Value, StoreFilter, StringComparison.Ordinal)))
|
||||
{
|
||||
StoreFilter = AnyToken;
|
||||
}
|
||||
|
||||
if (!Engines.Any(c => string.Equals(c.Value, EngineFilter, StringComparison.Ordinal)))
|
||||
{
|
||||
EngineFilter = AnyToken;
|
||||
}
|
||||
}
|
||||
|
||||
private static void Replace(ObservableCollection<Choice<string>> target, Choice<string>[] wanted)
|
||||
{
|
||||
if (target.SequenceEqual(wanted))
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
target.Clear();
|
||||
foreach (Choice<string> choice in wanted)
|
||||
{
|
||||
target.Add(choice);
|
||||
}
|
||||
}
|
||||
|
||||
private bool Passes(GameCardViewModel c) =>
|
||||
(StoreFilter.Length == 0 || string.Equals(c.PlatformToken, StoreFilter, StringComparison.Ordinal))
|
||||
&& (EngineFilter.Length == 0 || string.Equals(c.EngineToken ?? UnknownEngineToken, EngineFilter, StringComparison.Ordinal))
|
||||
&& (StateFilter == GamesStateFilter.All || c.State == StateFilter)
|
||||
&& InstalledFilter switch { YesNoFilter.Yes => !c.NotInstalled, YesNoFilter.No => c.NotInstalled, _ => true }
|
||||
&& PlayedFilter switch { YesNoFilter.Yes => c.SessionCount > 0, YesNoFilter.No => c.SessionCount == 0, _ => true };
|
||||
|
||||
partial void OnListViewChanged(bool value)
|
||||
{
|
||||
if (_viewRead && _settings is not null)
|
||||
@@ -354,7 +557,7 @@ public sealed partial class GamesViewModel : ObservableObject
|
||||
|
||||
private void Apply()
|
||||
{
|
||||
IEnumerable<GameCardViewModel> shown = _all;
|
||||
IEnumerable<GameCardViewModel> shown = _all.Where(Passes);
|
||||
string q = Search.Trim();
|
||||
if (q.Length > 0)
|
||||
{
|
||||
@@ -368,13 +571,47 @@ public sealed partial class GamesViewModel : ObservableObject
|
||||
_ => shown.OrderBy(static c => c.Name, StringComparer.CurrentCultureIgnoreCase),
|
||||
};
|
||||
|
||||
Games.Clear();
|
||||
foreach (GameCardViewModel card in shown)
|
||||
{
|
||||
Games.Add(card);
|
||||
}
|
||||
|
||||
Sync(Games, [.. shown]);
|
||||
IsEmpty = _all.Count == 0;
|
||||
NoMatch = _all.Count > 0 && Games.Count == 0;
|
||||
IsFiltered = q.Length > 0 || StoreFilter.Length > 0 || EngineFilter.Length > 0 || StateFilter != GamesStateFilter.All
|
||||
|| InstalledFilter != YesNoFilter.All || PlayedFilter != YesNoFilter.All;
|
||||
HeaderText = IsFiltered
|
||||
? string.Format(CultureInfo.CurrentCulture, Strings.Games_Header_Filtered_Format, Games.Count, _all.Count)
|
||||
: string.Format(CultureInfo.CurrentCulture, Strings.Games_Header_Count_Format, _all.Count);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Makes <paramref name="target"/> list <paramref name="wanted"/>, in its order, by removing, moving and inserting —
|
||||
/// never clearing (beta.34): a card that stays is the element already on screen, and the panel builds only the new.
|
||||
/// </summary>
|
||||
internal static void Sync(ObservableCollection<GameCardViewModel> target, IReadOnlyList<GameCardViewModel> wanted)
|
||||
{
|
||||
var keep = new HashSet<GameCardViewModel>(wanted);
|
||||
for (int i = target.Count - 1; i >= 0; i--)
|
||||
{
|
||||
if (!keep.Contains(target[i]))
|
||||
{
|
||||
target.RemoveAt(i);
|
||||
}
|
||||
}
|
||||
|
||||
for (int i = 0; i < wanted.Count; i++)
|
||||
{
|
||||
if (i < target.Count && ReferenceEquals(target[i], wanted[i]))
|
||||
{
|
||||
continue;
|
||||
}
|
||||
|
||||
int at = target.IndexOf(wanted[i]);
|
||||
if (at >= 0)
|
||||
{
|
||||
target.Move(at, i);
|
||||
}
|
||||
else
|
||||
{
|
||||
target.Insert(i, wanted[i]);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
// SPDX-License-Identifier: GPL-3.0-only
|
||||
// Copyright (C) 2026 poli0981 - additional terms under GPLv3 section 7: see NOTICE
|
||||
|
||||
namespace FrameLedger.App.ViewModels;
|
||||
|
||||
/// <summary>A two-way filter's three choices (beta.34, D85): everything, only the ones that are, only the ones that are not.</summary>
|
||||
public enum YesNoFilter
|
||||
{
|
||||
All = 0,
|
||||
Yes,
|
||||
No,
|
||||
}
|
||||
@@ -214,4 +214,50 @@ public sealed class CompareViewModelTests
|
||||
CultureInfo.CurrentCulture = previousCulture;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// beta.34 (owner request 2026-11-06, D85): Compare lists every session — it was the newest 200 — and filters them by game,
|
||||
/// tier and frame generation; a ticked session stays listed whatever the filters say, and the count says how many of how
|
||||
/// many are shown.
|
||||
/// </summary>
|
||||
[System.Diagnostics.CodeAnalysis.SuppressMessage("Performance", "CA1863:Use 'CompositeFormat'", Justification = "the format strings are resources that follow the UI culture")]
|
||||
[Fact]
|
||||
public async Task TheFiltersNarrowTheListAndATickedSessionStaysOnIt()
|
||||
{
|
||||
await using ScratchLedger s = await ScratchLedger.OpenAsync();
|
||||
GameRow a = await s.GameAsync("Alpha");
|
||||
GameRow b = await s.GameAsync("Beta");
|
||||
DateTimeOffset now = DateTimeOffset.UtcNow;
|
||||
_ = await s.SessionAsync(a.Id, now.AddHours(-5), fgMode: "dlssg", native: 60, displayed: 180, factor: 3);
|
||||
_ = await s.SessionAsync(a.Id, now.AddHours(-4), fgMode: "none");
|
||||
_ = await s.SessionAsync(b.Id, now.AddHours(-3), fgMode: "none");
|
||||
_ = await s.SessionAsync(b.Id, now.AddHours(-2), hooked: false);
|
||||
CompareViewModel vm = await BuildAsync(s, new ScriptedMixed(answer: true));
|
||||
|
||||
vm.Candidates.Should().HaveCount(4);
|
||||
vm.CountText.Should().Be(string.Format(CultureInfo.CurrentCulture, Strings.Compare_Count_Format, 4));
|
||||
vm.Games.Select(static g => g.Label).Should().Equal([Strings.Compare_Filter_Game_All, "Alpha", "Beta"]);
|
||||
|
||||
vm.GameFilter = a.Id;
|
||||
vm.Candidates.Should().HaveCount(2).And.OnlyContain(c => c.GameId == a.Id);
|
||||
vm.CountText.Should().Be(string.Format(CultureInfo.CurrentCulture, Strings.Compare_Count_Filtered_Format, 2, 4));
|
||||
|
||||
vm.FrameGenerationFilter = YesNoFilter.Yes;
|
||||
vm.Candidates.Should().ContainSingle().Which.HasFrameGeneration.Should().BeTrue();
|
||||
vm.Candidates[0].IsSelected = true;
|
||||
|
||||
vm.GameFilter = b.Id;
|
||||
vm.FrameGenerationFilter = YesNoFilter.All;
|
||||
vm.TierFilter = CompareTierFilter.NotMeasured;
|
||||
vm.Candidates.Should().HaveCount(2, "Beta's unmeasured session, and the ticked one, which a filter never hides");
|
||||
vm.Candidates.Count(static c => c.IsSelected).Should().Be(1);
|
||||
vm.SelectedCount.Should().Be(1);
|
||||
|
||||
vm.ClearSelectionCommand.Execute(null);
|
||||
vm.SelectedCount.Should().Be(0);
|
||||
vm.ClearFiltersCommand.Execute(null);
|
||||
vm.Candidates.Should().HaveCount(4);
|
||||
vm.Candidates.Single(static c => c.HasFrameGeneration is null).TierText.Should().Be(Strings.Tier_NotHooked);
|
||||
vm.Candidates.Should().OnlyContain(static c => c.SettingsChangedText.Length > 0, "a dash where nothing changed — the column was blank");
|
||||
}
|
||||
}
|
||||
@@ -317,6 +317,109 @@ public sealed class GamesViewModelTests
|
||||
vm.HeaderText.Should().EndWith("2");
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// beta.34 (owner request 2026-11-06, "Games stalls 0.5–1.5 s"): the cards are listed before any executable is checked —
|
||||
/// a sleeping USB drive took a second or more to answer, and no card was shown until every one had — and each card
|
||||
/// gets its pill when its check answers.
|
||||
/// </summary>
|
||||
[Fact]
|
||||
public async Task TheCardsComeBeforeTheExecutableChecksAndThePillAfter()
|
||||
{
|
||||
await using ScratchLedger s = await ScratchLedger.OpenAsync();
|
||||
_ = await s.GameAsync("Alpha");
|
||||
_ = await s.GameAsync("Bravo");
|
||||
var bound = TimeSpan.FromSeconds(30);
|
||||
using var checking = new ManualResetEventSlim();
|
||||
using var mayAnswer = new ManualResetEventSlim();
|
||||
bool Asleep(string path)
|
||||
{
|
||||
checking.Set();
|
||||
_ = mayAnswer.Wait(bound, Ct);
|
||||
return false;
|
||||
}
|
||||
|
||||
var selection = new GameSelection();
|
||||
var nav = new NoNavigation();
|
||||
var vm = new GamesViewModel(s.Library, selection, nav, new AddGameFlow(s.Library, new NoPicker(), selection, nav, new NoStrip()), executableExists: Asleep);
|
||||
Task load = vm.Pending;
|
||||
try
|
||||
{
|
||||
checking.Wait(bound, Ct).Should().BeTrue("the checks begin once the cards are listed");
|
||||
vm.Games.Should().HaveCount(2, "the cards are on the page while the drive is still answering");
|
||||
vm.Games.Should().OnlyContain(static g => !g.NotInstalled, "not known yet, so no pill");
|
||||
}
|
||||
finally
|
||||
{
|
||||
mayAnswer.Set();
|
||||
}
|
||||
|
||||
await load;
|
||||
vm.Games.Should().OnlyContain(static g => g.NotInstalled, "the answer came, and each card has its pill");
|
||||
vm.Games.Should().OnlyContain(static g => g.NotInstalledToolTip != null && g.StatusText.Contains(Strings.Games_Card_NotInstalled, StringComparison.Ordinal));
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// beta.34: the page is kept by its window and shown again on a later visit, so it reads the library again then — what
|
||||
/// happened while it was away appears — and a read keeps every card that would look the same, so the cards on screen are
|
||||
/// not built again.
|
||||
/// </summary>
|
||||
[Fact]
|
||||
public async Task APageShownAgainReadsTheLibraryAndKeepsTheCardsThatLookTheSame()
|
||||
{
|
||||
await using ScratchLedger s = await ScratchLedger.OpenAsync();
|
||||
GameRow alpha = await s.GameAsync("Alpha");
|
||||
_ = await s.GameAsync("Bravo");
|
||||
var selection = new GameSelection();
|
||||
var nav = new NoNavigation();
|
||||
var vm = new GamesViewModel(s.Library, selection, nav, new AddGameFlow(s.Library, new NoPicker(), selection, nav, new NoStrip()));
|
||||
Task first = vm.Pending;
|
||||
await first;
|
||||
vm.Attach();
|
||||
vm.Pending.Should().BeSameAs(first, "the first Loaded follows the constructor's own read");
|
||||
GameCardViewModel alphaCard = vm.Games.Single(static g => string.Equals(g.Name, "Alpha", StringComparison.Ordinal));
|
||||
GameCardViewModel bravoCard = vm.Games.Single(static g => string.Equals(g.Name, "Bravo", StringComparison.Ordinal));
|
||||
|
||||
vm.Detach();
|
||||
_ = await s.GameAsync("Charlie");
|
||||
_ = await s.SessionAsync(alpha.Id, DateTimeOffset.UtcNow);
|
||||
vm.Attach();
|
||||
Task again = vm.Pending;
|
||||
again.Should().NotBeSameAs(first, "shown again, the page reads the library again");
|
||||
await again;
|
||||
|
||||
vm.Games.Select(static g => g.Name).Should().Equal(["Alpha", "Bravo", "Charlie"]);
|
||||
vm.HeaderText.Should().EndWith("3");
|
||||
vm.Games.Single(static g => string.Equals(g.Name, "Bravo", StringComparison.Ordinal)).Should().BeSameAs(bravoCard, "it looks the same, so it is the card on screen");
|
||||
GameCardViewModel alphaNow = vm.Games.Single(static g => string.Equals(g.Name, "Alpha", StringComparison.Ordinal));
|
||||
alphaNow.Should().NotBeSameAs(alphaCard, "its session count changed");
|
||||
alphaNow.SessionCount.Should().Be(1);
|
||||
}
|
||||
|
||||
private static GameRow Row(long id) => new()
|
||||
{
|
||||
Id = id,
|
||||
Name = "G" + id.ToString(CultureInfo.InvariantCulture),
|
||||
Fingerprint = new() { ExePath = @"C:\Games\g.exe", SizeBytes = 1, MtimeUnixMs = 2 },
|
||||
HookEnabled = false,
|
||||
HookCrashCount = 0,
|
||||
AddedAt = DateTimeOffset.UnixEpoch,
|
||||
UpdatedAt = DateTimeOffset.UnixEpoch,
|
||||
};
|
||||
|
||||
[Fact]
|
||||
public void SyncRemovesMovesAndInsertsWithoutClearing()
|
||||
{
|
||||
GameCardViewModel[] c = [.. Enumerable.Range(1, 5).Select(static i => new GameCardViewModel(new GameCard(Row(i), null)))];
|
||||
var shown = new System.Collections.ObjectModel.ObservableCollection<GameCardViewModel>([c[0], c[1], c[2], c[3]]);
|
||||
int resets = 0;
|
||||
shown.CollectionChanged += (_, e) => resets += e.Action == System.Collections.Specialized.NotifyCollectionChangedAction.Reset ? 1 : 0;
|
||||
|
||||
GamesViewModel.Sync(shown, [c[3], c[0], c[4], c[2]]);
|
||||
|
||||
shown.Should().Equal([c[3], c[0], c[4], c[2]]);
|
||||
resets.Should().Be(0, "never a Reset: the cards that stay keep their elements");
|
||||
}
|
||||
|
||||
[Theory]
|
||||
[InlineData(1200, 3)]
|
||||
[InlineData(1248, 4)]
|
||||
@@ -361,4 +464,50 @@ public sealed class GamesViewModelTests
|
||||
Strings.Culture = previous;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// beta.34 (owner request 2026-11-06, D85): the library filters by store, engine, state, installed and played; the stores
|
||||
/// and engines are the ones the library holds; the header counts what is shown of all; Clear filters undoes them.
|
||||
/// </summary>
|
||||
[System.Diagnostics.CodeAnalysis.SuppressMessage("Performance", "CA1863:Use 'CompositeFormat'", Justification = "the format strings are resources that follow the UI culture")]
|
||||
[Fact]
|
||||
public async Task TheFiltersNarrowTheLibraryAndTheHeaderCountsWhatIsShown()
|
||||
{
|
||||
await using ScratchLedger s = await ScratchLedger.OpenAsync();
|
||||
GameRow alpha = await s.GameAsync("Alpha");
|
||||
_ = await s.GameAsync("Bravo");
|
||||
_ = await s.GameAsync("Charlie");
|
||||
_ = await s.SessionAsync(alpha.Id, DateTimeOffset.UtcNow);
|
||||
var selection = new GameSelection();
|
||||
var nav = new NoNavigation();
|
||||
var vm = new GamesViewModel(s.Library, selection, nav, new AddGameFlow(s.Library, new NoPicker(), selection, nav, new NoStrip()),
|
||||
executableExists: p => !p.Contains("Charlie", StringComparison.OrdinalIgnoreCase));
|
||||
Task load = vm.Pending;
|
||||
await load;
|
||||
|
||||
vm.Stores.Should().NotBeEmpty();
|
||||
vm.Stores[0].Value.Should().Be(GamesViewModel.AnyToken);
|
||||
vm.Engines[0].Value.Should().Be(GamesViewModel.AnyToken);
|
||||
vm.IsFiltered.Should().BeFalse();
|
||||
vm.HeaderText.Should().EndWith("3");
|
||||
|
||||
vm.PlayedFilter = YesNoFilter.Yes;
|
||||
vm.Games.Select(static g => g.Name).Should().Equal(["Alpha"]);
|
||||
vm.IsFiltered.Should().BeTrue();
|
||||
vm.HeaderText.Should().Be(string.Format(CultureInfo.CurrentCulture, Strings.Games_Header_Filtered_Format, 1, 3));
|
||||
|
||||
vm.PlayedFilter = YesNoFilter.No;
|
||||
vm.InstalledFilter = YesNoFilter.No;
|
||||
vm.Games.Select(static g => g.Name).Should().Equal(["Charlie"], "never played, and its executable is not on disk");
|
||||
|
||||
vm.InstalledFilter = YesNoFilter.All;
|
||||
vm.StateFilter = GamesStateFilter.HookingOn;
|
||||
vm.Games.Should().BeEmpty("hooking is off for every scratch entry");
|
||||
vm.NoMatch.Should().BeTrue();
|
||||
|
||||
vm.ClearFiltersCommand.Execute(null);
|
||||
vm.Games.Should().HaveCount(3);
|
||||
vm.IsFiltered.Should().BeFalse();
|
||||
vm.HeaderText.Should().EndWith("3");
|
||||
}
|
||||
}
|
||||
@@ -713,4 +713,27 @@ public sealed partial class PagesLoadTests
|
||||
seen.Windows.Should().Be(2);
|
||||
seen.AfterClose.Should().Equal([first], "a closed window is forgotten, and the next open builds a new one");
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// beta.34 (owner request 2026-11-06, D86): the selected page keeps its name in the pane. WPF UI's LeftFluent template
|
||||
/// animates the label to height 0 when an item becomes active; ours is the same template without that.
|
||||
/// </summary>
|
||||
[Fact]
|
||||
public async Task TheSelectedPaneItemKeepsItsLabel()
|
||||
{
|
||||
(double Height, double Opacity, double LabelHeight) seen = await OnStaAsync(() =>
|
||||
{
|
||||
var template = (System.Windows.Controls.ControlTemplate)System.Windows.Application.Current.FindResource("FlLeftFluentNavigationViewItemTemplate");
|
||||
var item = new Wpf.Ui.Controls.NavigationViewItem { Content = "Compare", Template = template };
|
||||
item.SetValue(Wpf.Ui.Controls.NavigationViewItem.IsActiveProperty, true);
|
||||
Render(item);
|
||||
var grid = (FrameworkElement)template.FindName("ContentGrid", item);
|
||||
var label = (FrameworkElement)template.FindName("ElementContentPresenter", item);
|
||||
return (grid.ActualHeight, grid.Opacity, label.ActualHeight);
|
||||
});
|
||||
|
||||
seen.Height.Should().BeGreaterThan(0, "the label's row keeps its height while the item is selected");
|
||||
seen.Opacity.Should().Be(1);
|
||||
seen.LabelHeight.Should().BeGreaterThan(0);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,64 @@
|
||||
// SPDX-License-Identifier: GPL-3.0-only
|
||||
// Copyright (C) 2026 poli0981 - additional terms under GPLv3 section 7: see NOTICE
|
||||
|
||||
using FluentAssertions;
|
||||
using FrameLedger.App.Pages;
|
||||
using FrameLedger.App.Services;
|
||||
using Microsoft.Extensions.DependencyInjection;
|
||||
using Wpf.Ui.Abstractions;
|
||||
|
||||
namespace FrameLedger.App.Tests;
|
||||
|
||||
/// <summary>
|
||||
/// beta.34 (owner request 2026-11-06): the library page is kept by the window that built it and shown again on a later
|
||||
/// visit; every other page is the container's, new each visit; a new window — a language change — builds its own.
|
||||
/// And the shell opens a rebuilt window on the page that was on screen, however it was reached.
|
||||
/// </summary>
|
||||
public sealed class WindowPageCacheTests
|
||||
{
|
||||
private sealed class NewEachTime : INavigationViewPageProvider
|
||||
{
|
||||
public int Built { get; private set; }
|
||||
|
||||
public object? GetPage(Type pageType)
|
||||
{
|
||||
Built++;
|
||||
return new object();
|
||||
}
|
||||
}
|
||||
|
||||
[Fact]
|
||||
public void TheLibraryIsKeptByItsWindowAndEveryOtherPageIsNewEachVisit()
|
||||
{
|
||||
var container = new NewEachTime();
|
||||
var window = new WindowPageCache(container);
|
||||
|
||||
object games = window.GetPage(typeof(GamesPage))!;
|
||||
window.GetPage(typeof(GamesPage)).Should().BeSameAs(games, "shown again, it is the page already built");
|
||||
window.GetPage(typeof(DashboardPage)).Should().NotBeSameAs(window.GetPage(typeof(DashboardPage)), "transient, as before");
|
||||
container.Built.Should().Be(3);
|
||||
|
||||
new WindowPageCache(container).GetPage(typeof(GamesPage)).Should().NotBeSameAs(games,
|
||||
"a rebuilt window builds its own, in its own language, and never shares one page between two windows");
|
||||
WindowPageCache.Kept.Should().BeEquivalentTo([typeof(GamesPage)]);
|
||||
FluentActions.Invoking(() => window.GetPage(null!)).Should().Throw<ArgumentNullException>();
|
||||
}
|
||||
|
||||
[Fact]
|
||||
public void ARebuildOpensOnThePageOnScreenHoweverItWasReached()
|
||||
{
|
||||
var shell = new ShellHost(new ServiceCollection().BuildServiceProvider(), null!, null!, new WindowClosePolicy());
|
||||
shell.Page.Should().Be<DashboardPage>();
|
||||
|
||||
shell.Remember(typeof(GameDetailPage));
|
||||
shell.NoteShown(live: true, page: new SettingsPageStandIn());
|
||||
shell.Page.Should().Be<SettingsPageStandIn>("a page reached by the pane is remembered too");
|
||||
|
||||
shell.NoteShown(live: false, page: new object());
|
||||
shell.Page.Should().Be<SettingsPageStandIn>("the closing window of a rebuild changes nothing");
|
||||
shell.NoteShown(live: true, page: null);
|
||||
shell.Page.Should().Be<SettingsPageStandIn>();
|
||||
}
|
||||
|
||||
private sealed class SettingsPageStandIn;
|
||||
}
|
||||
@@ -7,7 +7,9 @@ WPF UI 4.3.0 (pinned), CommunityToolkit.Mvvm, ScottPlot for charts and Markdig f
|
||||
## How it is put together
|
||||
|
||||
- A .NET Generic Host with dependency injection. Pages and their view models are transient — a page is made again on
|
||||
every navigation, so state lives in the view models' services and the database, never in a page. A view model that
|
||||
every navigation, so state lives in the view models' services and the database, never in a page. The one exception
|
||||
(beta.34): the window keeps the library page it built (`WindowPageCache`) and the page reads the library again each
|
||||
time it is shown. A view model that
|
||||
listens to a service attaches on its page's Loaded and detaches on Unloaded, and is never `IDisposable`: the container
|
||||
keeps every transient disposable it makes until the App exits.
|
||||
- The ledger's reads run on the thread that calls them (Microsoft.Data.Sqlite completes its asynchronous calls
|
||||
|
||||
Reference in new issue
Block a user