summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Sora/Views/Post/Details/PostDetailsImageView.swift6
-rw-r--r--Sora/Views/Post/Grid/PostGridView.swift2
2 files changed, 4 insertions, 4 deletions
diff --git a/Sora/Views/Post/Details/PostDetailsImageView.swift b/Sora/Views/Post/Details/PostDetailsImageView.swift
index 483d435..0ab28c4 100644
--- a/Sora/Views/Post/Details/PostDetailsImageView.swift
+++ b/Sora/Views/Post/Details/PostDetailsImageView.swift
@@ -213,10 +213,10 @@ struct PostDetailsImageView<Placeholder: View>: View {
#endif
private func openURL(_ url: URL) {
- #if os(iOS)
- UIApplication.shared.open(url)
- #else
+ #if os(macOS)
NSWorkspace.shared.open(url)
+ #else
+ UIApplication.shared.open(url)
#endif
}
diff --git a/Sora/Views/Post/Grid/PostGridView.swift b/Sora/Views/Post/Grid/PostGridView.swift
index 1d90f42..9fd384c 100644
--- a/Sora/Views/Post/Grid/PostGridView.swift
+++ b/Sora/Views/Post/Grid/PostGridView.swift
@@ -164,7 +164,7 @@ struct PostGridView: View {
)
.frame(minHeight: 250)
}
- #if !os(macOS)
+ #if os(iOS)
.gesture(
DragGesture()
.onEnded { value in