The Maps app on macOS always zooms the same way (two fingers up to zoom in, two fingers down to zoom out) when the shift key is held down, regardless of whether natural scrolling is turned off. I'd like to replicate this same behavior using UIPanGestureRecognizer, but the translation is always inverted whenever I disable natural scrolling. How can I detect if natural scrolling is enabled or disabled when the pan gesture is detected?
Post
Replies
Boosts
Views
Activity
I am unable to use a framework that uses SwiftUI, built with the Xcode 16 release candidate, in Xcode 15.4. Attempting to build an app that uses the pre-built framework results in "Cannot find type 'SwiftUICore' in scope errors in the framework's private swift interface (.private.swiftinterface) file. For example
error: cannot find type 'SwiftUICore' in scope
@_Concurrency.MainActor @preconcurrency public var body: some SwiftUICore.View {
^~~~~~~~~~~
The problem is reproducible by creating a new framework project in Xcode 16, adding SwiftUI code to it, adjusting the deployment target, building the framework, then creating a new app project in Xcode 15.4, adding the framework to it, and attempting to build. In my test framework, I added the following type:
public struct BoldText: View {
let string: String
public init(_ string: String) {
self.string = string
}
public var body: some View {
Text(string).bold()
}
}
When I removed that type, a build of the framework with Xcode 16 became useable in Xcode 15.4.
Is this expected or is this a bug?