Post

Replies

Boosts

Views

Activity

Reply to Beta developer options
Ok. Quit/re open Xcode shouldn't be necessary; perhaps a deeper analysis by Apple with a Feedback Assistant could help. If developer option lastly appears after running an app from Xcode, please set above as valid answer for who will read.
Jul ’21
Reply to ITMS-90034: Missing or invalid signature
Perhaps the fix has been implemented in Xcode 12.5 Beta 3: Resolved Issues Fixed an issue that caused OS X 10.11 and earlier to reject packages signed on OS X 10.11 and earlier. (71695608) Known Issues OS X 10.11 and earlier may reject code signatures added to universal binaries by Xcode 12.5. (70724583) (FB8830007) Workaround: Specify --digest-algorithm=sha1,sha256 to the codesign utility at signing time. In Xcode, specify this using the OTHER_CODE_SIGN_FLAGS build setting.
Mar ’21
Reply to Calling a view from 2 different places, one works one doesn't
I understood that you would a single click on the "+" button create a new List's item and follows its link. If it is so the NavigationLink init has to be the one with a tag and reference to a tags' selection, the addJob function have to create the new job's item and set the reference to point to it. The simplified code below use an, improper, set of Int as job's ID. import SwiftUI struct ContentView: View {     var body: some View { JobsView()     } } extension Int: Identifiable { public var id: Self { self } } struct JobsView: View { @State private var jobs = [0, 1, 2] @State private var selection: Int? = nil var body: some View { NavigationView { List { ForEach(jobs) { job in NavigationLink("job \(job)",   destination: JobOverView(job: job),   tag: job,   selection: $selection) } } .toolbar { Button(action: addJob,   label: {Image(systemName:"plus")} ) } .navigationTitle("Jobs") } } private func addJob() { jobs.append(jobs.last!+1) selection = jobs.last   } } struct JobOverView: View { let job: Int var body: some View { Label("Job Info \(job)", systemImage:  "chevron.down.circle.fill") } }
Feb ’21
Reply to Restore
In my case I restored from iCloud as well as from iMac backup and both worked. Anyway the restoration don't change the iPhone boot, so in case of a failure (perhaps a power loss) the restore could be done again. The restore from a full, password protected, backup in iMac restored also sensitive data as passwords and fingerprints, in either case password will be re-synched from iCloud, if the were there, and fingerprints have to be re-recorded.
Feb ’21
Reply to How to use NavigationView in a DocumentGroup on iPad
Using Reference File Document Group followed by NavigationView I've been able to have a document group that open a navigation view, which have the sidebar. Here an extract: import SwiftUI @main struct MyApp: App { var body: some Scene { DocumentGroup(newDocument: { () -> myDocumentClass in // Create a new document return myDocumentClass() },   editor: { (file: ReferenceFileDocumentConfiguration<myDocumentClass>) -> ContentView in return ContentView() } ) } } class myDocumentClass: ReferenceFileDocument { typealias Snapshot = ContentView var myData: Snapshot ... } struct ContentView: View { var body: some View { NavigationView { sideBar() mainView() } .navigationViewStyle(DoubleColumnNavigationViewStyle()) } }
Oct ’20
Reply to How to have Codable Color?
I found by myself that is possible since on iOS 14. func encode(to encoder: Encoder) throws { var container = encoder.container(keyedBy: CodingKeys.self) if #available(iOS 14.0, *) { let convertedColor = UIColor(mycolor) let colorData = try NSKeyedArchiver.archivedData(withRootObject: convertedColor, requiringSecureCoding: false) try container.encode(colorData, forKey: .color) } else { // Fallback on earlier versions } }
Aug ’20