Post

Replies

Boosts

Views

Activity

SwiftUI crash when using wheel style Picker in form in form
I'm using a wheel style picker in a form that I navigate to using a NavigationLink. When I rotate the wheel, the app crashes. If I remove the form in SubForm, the crash disappears, but then the looks are completely different. I'd like the looks of the form, but obviously I don't want the crash. Any suggestions? (iOS15 in a simulator using Xcode 13) struct SubForm: View { @State private var selection = 1 var body: some View { Form { Section(header: Text("Another title")) { Picker("Pick me", selection: $selection) { Text("First item").tag(0) Text("Second item").tag(1) }.pickerStyle(.wheel) } } } } struct ContentView: View { var body: some View { NavigationView { Form { Section(header: Text("A title")) { NavigationLink("Subview", destination: { SubForm() }) } } } } }
2
1
1.7k
Oct ’21
How to access the Action Button on the Apple Watch Ultra
I'm very exciting about the Apple Watch Ultra, and I'd like to build in support for the action button in my app. There seems to be no information available, any idea how to do this?
Replies
4
Boosts
0
Views
2.1k
Activity
Dec ’22
SwiftUI crash when using wheel style Picker in form in form
I'm using a wheel style picker in a form that I navigate to using a NavigationLink. When I rotate the wheel, the app crashes. If I remove the form in SubForm, the crash disappears, but then the looks are completely different. I'd like the looks of the form, but obviously I don't want the crash. Any suggestions? (iOS15 in a simulator using Xcode 13) struct SubForm: View { @State private var selection = 1 var body: some View { Form { Section(header: Text("Another title")) { Picker("Pick me", selection: $selection) { Text("First item").tag(0) Text("Second item").tag(1) }.pickerStyle(.wheel) } } } } struct ContentView: View { var body: some View { NavigationView { Form { Section(header: Text("A title")) { NavigationLink("Subview", destination: { SubForm() }) } } } } }
Replies
2
Boosts
1
Views
1.7k
Activity
Oct ’21