From 8634a3c7575f0db23a22f5b61b93e80deeea9dcb Mon Sep 17 00:00:00 2001 From: eonist <30n1st@gmail.com> Date: Thu, 24 Oct 2024 02:25:26 +0200 Subject: [PATCH] Change to dispatch main --- .../xcshareddata/swiftpm/Package.resolved | 2 +- .../SplitViewContainer+Content.swift | 20 +++++++++---------- 2 files changed, 11 insertions(+), 11 deletions(-) diff --git a/ExampleProject/ExampleProject.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved b/ExampleProject/ExampleProject.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved index 9a44e69..3642c97 100644 --- a/ExampleProject/ExampleProject.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved +++ b/ExampleProject/ExampleProject.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved @@ -16,7 +16,7 @@ "location" : "https://github.com/sentryco/SplitViewKit", "state" : { "branch" : "main", - "revision" : "5bb09d711f43a03699ab57caaa64538ea229f70e" + "revision" : "c04101dad75f71ec914805ad5ad2d9db687cd1c5" } } ], diff --git a/Sources/SplitViewKit/SplitViewContainer+Content.swift b/Sources/SplitViewKit/SplitViewContainer+Content.swift index 6eee330..dc22b27 100644 --- a/Sources/SplitViewKit/SplitViewContainer+Content.swift +++ b/Sources/SplitViewKit/SplitViewContainer+Content.swift @@ -61,18 +61,18 @@ extension SplitViewContainer { let _ = { Swift.print("📐 Geometry changed: \(geometry.size) ") }() -// let _ = { -// DispatchQueue.main.async { -// winWidth = geometry.size.width -// } -// }() - navigationSplitView() - .id(refreshID) - .onAppear { - Swift.print("✨ onAppear") - winWidth = geometry.size.width + let _ = { + DispatchQueue.main.async { refreshID = UUID() } + }() + navigationSplitView() + .id(refreshID) +// .onAppear { +// Swift.print("✨ onAppear") +// winWidth = geometry.size.width +// refreshID = UUID() +// } }