Run Windows games on Apple Silicon — free, open source, with an open compatibility database that tells you what actually works.
Swift apple-silicond3dmetaldxmtdxvkfexgame-porting-toolkitgamingmac-gamingmacosmetalmoltenvksteamswiftuivkd3d-protonwhisky-alternativewindows-gameswinewine-wrapper
uninstall: the message stops repeating the title's question (seen on screen, it read as a stutter)
Gauthier Piarretted0575b8851d7
diff --git a/Sources/HighballApp/HighballApp.swift b/Sources/HighballApp/HighballApp.swiftindex 1c0645c..5da8f71 100644--- a/Sources/HighballApp/HighballApp.swift+++ b/Sources/HighballApp/HighballApp.swift@@ -348,7 +348,7 @@ private extension View {}Button(L("Cancel"), role: .cancel) { state.pendingUninstall = nil }} message: { pending in- Text(Uninstall.confirmation(title: pending.item.title, route: pending.route, sizeOnDisk: pending.item.sizeOnDisk))+ Text(Uninstall.confirmation(route: pending.route, sizeOnDisk: pending.item.sizeOnDisk))}}diff --git a/Sources/HighballKit/Uninstall.swift b/Sources/HighballKit/Uninstall.swiftindex a80731c..22d3316 100644--- a/Sources/HighballKit/Uninstall.swift+++ b/Sources/HighballKit/Uninstall.swift@@ -43,18 +43,18 @@ public enum Uninstall {}}- /// The question asked before anything happens. It names the game, says who does the removing,- /// and says how much space comes back when that is known, because "are you sure" without a- /// figure is a question nobody can answer.- public static func confirmation(title: String, route: Route, sizeOnDisk: Int64) -> String {+ /// What is said under the question, which is "Remove <game>?" and is not repeated here: it+ /// says who does the removing and how much space comes back when that is known, because+ /// "are you sure" without a figure is a question nobody can answer.+ public static func confirmation(route: Route, sizeOnDisk: Int64) -> String {let size = sizeOnDisk > 0 ? " That frees \(ByteCountFormatter.string(fromByteCount: sizeOnDisk, countStyle: .file))." : ""switch route {case .steam:- return "Remove \(title)? Steam does the uninstalling and asks you to confirm in its own window, so its library stays right.\(size)"+ return "Steam does the uninstalling and asks you to confirm in its own window, so its library stays right.\(size)"case .epic:- return "Remove \(title)? The Epic tools do the uninstalling, so their library stays right.\(size)"+ return "The Epic tools do the uninstalling, so their library stays right.\(size)"case .windowsUninstaller:- return "Remove \(title)? Highball opens Windows' Add or Remove Programs in this environment, where you pick it from the list. A game with no uninstaller of its own will not be in that list, and then the only way to remove it is to delete the environment."+ return "Highball opens Windows' Add or Remove Programs in this environment, where you pick it from the list. A game with no uninstaller of its own will not be in that list, and then the only way to remove it is to delete the environment."case let .none(reason):return reason}diff --git a/Tests/HighballKitTests/UninstallTests.swift b/Tests/HighballKitTests/UninstallTests.swiftindex c3dca1d..318a321 100644--- a/Tests/HighballKitTests/UninstallTests.swift+++ b/Tests/HighballKitTests/UninstallTests.swift@@ -37,18 +37,20 @@ final class UninstallTests: XCTestCase {XCTAssertTrue(Uninstall.isActionable(.windowsUninstaller))}- func testTheQuestionNamesWhoRemovesItAndWhatComesBack() {- let steam = Uninstall.confirmation(title: "Portal 2", route: .steam(appID: 620), sizeOnDisk: 12_884_901_888)- XCTAssertTrue(steam.contains("Portal 2"), steam)+ /// Seen on screen 2026-09-22: the alert's title already asks "Remove <game>?", so a message+ /// that asks it again reads as a stutter. The message says who removes it and what comes back.+ func testTheMessageSaysWhoRemovesItAndWhatComesBackWithoutRepeatingTheQuestion() {+ let steam = Uninstall.confirmation(route: .steam(appID: 620), sizeOnDisk: 12_884_901_888)+ XCTAssertFalse(steam.hasPrefix("Remove"), "the title asks the question, not the message: \(steam)")XCTAssertTrue(steam.contains("Steam does the uninstalling"), steam)XCTAssertTrue(steam.contains("GB"), "a confirmation without a figure is unanswerable: \(steam)")- let unknownSize = Uninstall.confirmation(title: "Portal 2", route: .steam(appID: 620), sizeOnDisk: 0)+ let unknownSize = Uninstall.confirmation(route: .steam(appID: 620), sizeOnDisk: 0)XCTAssertFalse(unknownSize.contains("frees"), "no invented figure when the size is unknown")}/// The Windows route can come up empty, and the question says so rather than promising.func testTheWindowsRouteAdmitsItMayNotListTheGame() {- let text = Uninstall.confirmation(title: "Dark Omen", route: .windowsUninstaller, sizeOnDisk: 0)+ let text = Uninstall.confirmation(route: .windowsUninstaller, sizeOnDisk: 0)XCTAssertTrue(text.contains("will not be in that list"), text)XCTAssertTrue(text.contains("delete the environment"), text)}@@ -56,7 +58,7 @@ final class UninstallTests: XCTestCase {func testTheReasonIsWhatAnUnroutableGameShows() {let route = Uninstall.route(for: item(.steam))guard case let .none(reason) = route else { return XCTFail("expected none") }- XCTAssertEqual(Uninstall.confirmation(title: "Portal 2", route: route, sizeOnDisk: 99), reason,+ XCTAssertEqual(Uninstall.confirmation(route: route, sizeOnDisk: 99), reason,"no size talk when nothing can be removed")}}