macos: Fallback to standard driver when no unobtrusive targets exist

This commit is contained in:
Mitchell Hashimoto
2025-10-09 17:08:21 -07:00
parent f2e5b8fb2d
commit f124bb4975
3 changed files with 121 additions and 5 deletions

View File

@@ -134,6 +134,23 @@ enum UpdateState: Equatable {
return false
}
func cancel() {
switch self {
case .checking(let checking):
checking.cancel()
case .updateAvailable(let available):
available.reply(.dismiss)
case .downloading(let downloading):
downloading.cancel()
case .readyToInstall(let ready):
ready.reply(.dismiss)
case .error(let err):
err.dismiss()
default:
break
}
}
static func == (lhs: UpdateState, rhs: UpdateState) -> Bool {
switch (lhs, rhs) {
case (.idle, .idle):