mirror of
https://github.com/ninxsoft/Mist.git
synced 2025-05-19 01:35:24 -04:00
Update ISO messaging for macOS Catalina 10.15 + Apple Silicon
This commit is contained in:
parent
5c804f50e3
commit
55efd48f00
3 changed files with 19 additions and 5 deletions
|
@ -16,7 +16,15 @@ struct InstallerExportView: View {
|
|||
private var exportISO: Bool = false
|
||||
@AppStorage("exportPackage")
|
||||
private var exportPackage: Bool = false
|
||||
var installer: Installer
|
||||
@Binding var exports: [InstallerExportType]
|
||||
private var isoCompatible: Bool {
|
||||
guard let architecture: Architecture = Hardware.architecture else {
|
||||
return false
|
||||
}
|
||||
|
||||
return architecture == .intel || (architecture == .appleSilicon && installer.bigSurOrNewer)
|
||||
}
|
||||
|
||||
var body: some View {
|
||||
VStack {
|
||||
|
@ -28,12 +36,18 @@ struct InstallerExportView: View {
|
|||
.disabled(exports.count == 1 && exportApplication)
|
||||
InstallerExportViewItem(exportType: .diskImage, selected: $exportDiskImage)
|
||||
.disabled(exports.count == 1 && exportDiskImage)
|
||||
InstallerExportViewItem(exportType: .iso, selected: $exportISO)
|
||||
.disabled(exports.count == 1 && exportISO)
|
||||
if isoCompatible {
|
||||
InstallerExportViewItem(exportType: .iso, selected: $exportISO)
|
||||
.disabled(exports.count == 1 && exportISO)
|
||||
}
|
||||
InstallerExportViewItem(exportType: .package, selected: $exportPackage)
|
||||
.disabled(exports.count == 1 && exportPackage)
|
||||
Spacer()
|
||||
}
|
||||
if !isoCompatible {
|
||||
Text("**Note:** ISOs are unavailable for building **macOS Catalina 10.15 and older** on [Apple Silicon Macs](https://support.apple.com/en-us/HT211814).")
|
||||
.padding(.top)
|
||||
}
|
||||
}
|
||||
.padding()
|
||||
.onChange(of: exportApplication) { _ in
|
||||
|
@ -79,6 +93,6 @@ struct InstallerExportView: View {
|
|||
|
||||
struct InstallerExportView_Previews: PreviewProvider {
|
||||
static var previews: some View {
|
||||
InstallerExportView(exports: .constant(InstallerExportType.allCases))
|
||||
InstallerExportView(installer: .example, exports: .constant(InstallerExportType.allCases))
|
||||
}
|
||||
}
|
||||
|
|
|
@ -81,7 +81,7 @@ struct InstallerListRow: View {
|
|||
openPanel.canChooseDirectories = true
|
||||
openPanel.allowsMultipleSelection = false
|
||||
openPanel.prompt = "Save"
|
||||
openPanel.accessoryView = NSHostingView(rootView: InstallerExportView(exports: $exports))
|
||||
openPanel.accessoryView = NSHostingView(rootView: InstallerExportView(installer: installer, exports: $exports))
|
||||
openPanel.isAccessoryViewDisclosed = true
|
||||
|
||||
Task {
|
||||
|
|
|
@ -13,7 +13,7 @@ struct SettingsISOsView: View {
|
|||
private let imageName: String = "ISO"
|
||||
private let title: String = "ISOs"
|
||||
// swiftlint:disable:next line_length
|
||||
private let description: String = "ISOs are Bootable macOS Installer Disk Images that can be restored on external USB drives, or used with virtualization software (ie. [Parallels Desktop](https://www.parallels.com/au/products/desktop/), [UTM](https://mac.getutm.app), [VMware Fusion](https://www.vmware.com/au/products/fusion.html), [VirtualBox](https://www.virtualbox.org)).\n\n**Note:** ISOs will fail to build when targeting **macOS Catalina 10.15 and older** on [Apple Silicon Macs](https://support.apple.com/en-us/HT211814)."
|
||||
private let description: String = "ISOs are Bootable macOS Installer Disk Images that can be restored on external USB drives, or used with virtualization software (ie. [Parallels Desktop](https://www.parallels.com/au/products/desktop/), [UTM](https://mac.getutm.app), [VMware Fusion](https://www.vmware.com/au/products/fusion.html), [VirtualBox](https://www.virtualbox.org)).\n\n**Note:** ISOs are unavailable for building **macOS Catalina 10.15 and older** on [Apple Silicon Macs](https://support.apple.com/en-us/HT211814)."
|
||||
|
||||
var body: some View {
|
||||
VStack(alignment: .leading) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue