mirror of
https://github.com/TomHarte/CLK.git
synced 2025-08-15 14:27:29 +00:00
Merge pull request #875 from TomHarte/InitialSelection
Ensures machine selection carries over sessions.
This commit is contained in:
@@ -56,6 +56,10 @@ class MachinePicker: NSObject {
|
|||||||
func establishStoredOptions() {
|
func establishStoredOptions() {
|
||||||
let standardUserDefaults = UserDefaults.standard
|
let standardUserDefaults = UserDefaults.standard
|
||||||
|
|
||||||
|
// TEMPORARY: remove the Apple IIgs option. It's not yet a fully-working machine; no need to publicise it.
|
||||||
|
let appleIIgsTabIndex = machineSelectionTabs.indexOfTabViewItem(withIdentifier: "appleiigs")
|
||||||
|
machineSelectionTabs.removeTabViewItem(machineSelectionTabs.tabViewItem(at: appleIIgsTabIndex))
|
||||||
|
|
||||||
// Machine type
|
// Machine type
|
||||||
if let machineIdentifier = standardUserDefaults.string(forKey: "new.machine") {
|
if let machineIdentifier = standardUserDefaults.string(forKey: "new.machine") {
|
||||||
// If I've changed my mind about visible tabs between versions, there may not be one that corresponds
|
// If I've changed my mind about visible tabs between versions, there may not be one that corresponds
|
||||||
@@ -105,10 +109,6 @@ class MachinePicker: NSObject {
|
|||||||
|
|
||||||
// ZX81
|
// ZX81
|
||||||
zx81MemorySizeButton.selectItem(withTag: standardUserDefaults.integer(forKey: "new.zx81MemorySize"))
|
zx81MemorySizeButton.selectItem(withTag: standardUserDefaults.integer(forKey: "new.zx81MemorySize"))
|
||||||
|
|
||||||
// TEMPORARY: remove the Apple IIgs option. It's not yet a fully-working machine; no need to publicise it.
|
|
||||||
let appleIIgsTabIndex = machineSelectionTabs.indexOfTabViewItem(withIdentifier: "appleiigs")
|
|
||||||
machineSelectionTabs.removeTabViewItem(machineSelectionTabs.tabViewItem(at: appleIIgsTabIndex))
|
|
||||||
}
|
}
|
||||||
|
|
||||||
fileprivate func storeOptions() {
|
fileprivate func storeOptions() {
|
||||||
|
Reference in New Issue
Block a user