Post

Replies

Boosts

Views

Activity

MapKit mapItemDetailAccessory Custom View
Hi all, It wasn't extensively covered in the "Unlock the power of places with MapKit" at WWDC, but is it possible to add your own views to the mapItemDetailAccessory? The default view is great, but I would like to add a button for opening a new window showing another view. The documentation is rather limited at the moment so I thought I would ask here. Thanks in advance.
0
0
36
19h
ModelActor Implementation Changes In Xcode 15 Beta 7
Hi all, There appears to be some changes to how ModelActors are implemented in Beta 7 of Xcode 15. In Beta 6, we had the DefaultModelExecutor object which we used to assign to the ModelActor's executor property. A simple example is shown below: final actor SimpleModelActor: ModelActor { let executor: any ModelExecutor init(modelContainer: ModelContainer) { let modelContext = ModelContext(modelContainer) executor = DefaultModelExecutor(context: modelContext) } func addItem() { let newItem = Item(timestamp: Date()) context.insert(newItem) try! context.save() } .... } However, it seems that the DefaultModelExecutor class has been removed for Beta 7, without any real replacement. Anyone know how to implement a ModelActor in the new beta? Thanks in advance.
2
0
985
Aug ’23
Xcode 15 Beta 6: App Runs With High CPU Usage
Hi all, I am creating a Mac application leveraging SwiftUI for the views and SwiftData for the persistent storage. Now, I have seen others have issues with high CPU usage in Xcode 15 Beta 5, and I seem to be encountering the same issue in Beta 6. Contrary to many though, I did not observe high CPU use in Beta 5. I have already done my best to resolve the issue, most notably refining my Models' properties to not use default values, etc, but I am still seeing CPU usage at 100%. Any idea on where I can look to further optimise my application? Massive thanks in advance.
1
0
1.1k
Aug ’23