Repository navigation
WIP: native dark mode on .NET 10 with scoped WinForms adapters - #1000
ObnubiladO wants to merge 18 commits into
Conversation
|
@Klocman @hazeliscoding @One-Simon — when you have a chance, could you advise whether this opt-in .NET 10 approach is directionally acceptable and which remaining areas should be prioritized? The prototype is usable but remains a draft with unresolved validation and product decisions. |
|
There's no point in having separate builds, just move everything to .NET 10. It would be best if you focused on just dark mode and piping required to make it work. |
|
Thanks, that makes sense. I've updated the branch so the shared build configuration targets the entire solution at .NET 10, removed the separate native-dark build/helper/output path, and dropped the unrelated ObjectListView column-DPI change. CI now uses the Windows 2025 / Visual Studio 2026 runner because the solution still has three COM-reference projects. The .NET 10 application project builds locally; the full-solution CI run is currently waiting for maintainer approval. I'll keep further work focused on dark mode and the plumbing required to support it. |
|
@Klocman @hazeliscoding @One-Simon — the requested direction is now implemented: the whole solution targets .NET 10, the separate native-dark build and unrelated DPI change are gone, and the branch is synchronized with BCU v6.3/current master. A full fork CI run passed the Visual Studio 2026 restore/build/publish and tests, along with the MFC launcher build. The equivalent upstream PR workflow is waiting for maintainer approval. I clarified the PR description to list the remaining maintainer decisions: whether the scoped WinForms-adapter structure is acceptable, the intended activation behavior, and which open validation items should be merge gates versus follow-up release checks. Feedback on those points would define the next work; the PR will remain a draft until the resulting required work is complete. |
|
Would a maintainer please approve this PR and #962 so that the workflows create artifacts that can be used for testing? |
|
The persisted Interface toggle and restart path are now ready for opt-in technical testing. A fresh portable build is available from fork CI run 36248632055 as artifact To try it:
I tested that exact cycle on the artifact: light → dark → light, with a new process after each restart and the persisted XML changing This is an unofficial experimental build. BCU normally runs elevated and its uninstall actions are live, so please begin with non-destructive inspection. Reports are most useful with the Windows version/build, display scaling, high-contrast state, exact steps, and screenshots of any unreadable, unthemed or incorrectly restored surface. The PR remains a draft; the current checklist still has 21 open release-validation items. |
|
|
||
| set netVer=net8.0 | ||
| set netVerFull=net8.0-windows10.0.18362.0 | ||
| set netVer=net10.0 |
There was a problem hiding this comment.
Could you update the installer alongside this change? installer/BcuSetup.iss still points to publish-AnyCPU-net8.0, while this script now produces publish-AnyCPU-net10.0. A clean installer build will reference a missing directory. The installer also still calls Dependency_AddDotNet80Desktop, so new installations would not get the .NET 10 Desktop Runtime.
There was a problem hiding this comment.
Fixed in 2893b52.
BcuSetup.issnow consumespublish-AnyCPU-net10.0.- The light installer calls a new
Dependency_AddDotNet100Desktophelper, which detectsMicrosoft.WindowsDesktop.App10.0.12 and downloads the official x86/x64 .NET 10 Desktop Runtime installers with enforced SHA-256 checksums. - I verified both downloaded binaries against Microsoft's published release-metadata SHA-512 values.
- Using an untouched output from the latest fork CI artifact, Inno Setup 6.4.3 successfully compiled
BCUninstaller_6.3.0_setup.exefrom the updated script.
A clean-machine runtime-download/install and upgrade replay remains tracked in the broader packaging checklist.
|
Updated opt-in technical test build: Download the portable ZIP · Release notes / testing instructions · SHA-256 checksum This supersedes the older artifact linked above and includes:
Fresh full fork CI rebuilt/published the solution and passed the native launcher build. The focused checker passed 15 dark-mode checks and 13 light-mode checks. The normal Test step returned success, but produced no TRX; no full-suite count is claimed. CI commit Extract into a separate folder and enable Settings > Interface > Use dark mode (restart required), then accept the restart. The .NET 10 Desktop Runtime is required. The ZIP's Normal elevation and uninstall actions remain active; begin with non-destructive inspection. Please report Windows version/build, display scaling, high-contrast state, exact steps, the build identifier and screenshots of any unreadable or unthemed surface. The PR remains a draft with its broader release-validation work still open. This is an unofficial portable test build, not an updated installer. |
BCU has no integrated dark mode. This draft moves the solution to .NET 10 and adds an experimental native WinForms dark mode through a persisted Interface setting. It is synchronized with BCU v6.3 and current upstream master (
30da609).Related discussion: #962. This PR stays focused on dark mode and the plumbing required for it; it does not include the broader core refactor or COM-removal proposal from that discussion.
What is implemented
OK/OKCancelmessage flows and the Feedback HTML surface receive dark rendering and keyboard/focus handling.Automatic system-theme following and live theme switching without a restart are not implemented. Normal elevation, scanning and uninstall actions remain active.
Build
On Windows with Visual Studio 2026 desktop/C++ tools and the .NET 10 SDK:
Then enable dark mode under Settings > Interface and accept the restart prompt.
See the architecture/build notes, WIP continuation guide, fork validation report, and regression checklist.
Current validation
Full fork CI run 37516481604 rebuilt and published the entire solution and passed the native MFC launcher build. Its focused helper/loading-dialog checker passed 15 dark-mode checks and 13 light-mode checks. Application/helper source is
b4805b4; temporary CI commit533c23cdiffers only in workflow configuration for triggering the run and executing that checker. The normal CI Test step returned success, but no TRX was produced/uploaded, so no full-suite result count is claimed.Local checks also covered actual helper launch/cancellation in both themes (16 dark, 14 light), plus visual inspection of the restored tree and blue scan progress on Windows 11 at 200% DPI. These controlled local runs used ordinary integrity; broader elevated, Windows/DPI and accessibility coverage remains open.
The earlier portable app host was tested through this full cycle:
WindowUseDarkMode=Trueis persisted.WindowUseDarkMode=Falseis persisted.That exercise exposed and fixed the .NET app-host restart target, single-instance mutex release, and save-before-relaunch ordering. Four focused unit cases cover preference on/off combined with high contrast on/off. Earlier UI campaigns cover the main inventory, Properties, all Settings pages, dialogs, tooltips, Feedback HTML, keyboard operation, contrast transitions, exports and the uninstall wizard up to its final summary without starting an uninstall.
The local application firewall blocks the generated repair-checker executable. Network-dependent validation therefore used the same harness DLL through the allowed .NET host; the new setting/restart cycle itself is offline and was unaffected.
Opt-in technical testing
Download the updated portable test ZIP, with release notes and testing instructions and SHA-256 checksum. This public prerelease contains the fresh full-CI package for
b4805b4and supersedes the earlier CI artifact linked in this PR.This is an unofficial experimental build and requires the .NET 10 Desktop Runtime. Extract it to a separate folder, launch
BCUninstaller.exenormally, and enable Settings > Interface > Use dark mode (restart required). Close Settings and accept the restart; clear the option and restart again to check light-mode recovery.The included
TESTING.txtprovides a disposable-file recipe for inspecting the separate delete helper without finding a real application to uninstall. Normal elevation and uninstall features are live, so begin with non-destructive inspection. This is a portable test package, not an updated installer.Useful reports include Windows version/build, display scaling, high-contrast state, the exact steps taken, and screenshots of any unreadable, unthemed or incorrectly restored surface.
Remaining work and maintainer input
The checklist has 21 open items. The main remaining groups are same-integrity elevated lifecycle/culture coverage, remaining wizard/progress/leftover states, Windows and physical-DPI coverage, real screen-reader and localization/RTL checks, resource stability, packaging, and disposable uninstall/backup/cleanup workflows.
Maintainer input is still requested on whether the scoped WinForms-adapter structure is acceptable and which open checklist items are required merge gates versus follow-up release validation. Approval of the upstream PR workflow would also produce an upstream-hosted artifact. Feedback defines the remaining merge work; the PR should stay a draft until that required scope is resolved.