From 573497ed52b63614b707d14723abb50f4f8118f9 Mon Sep 17 00:00:00 2001 From: Thomas Ricouard Date: Tue, 4 Apr 2023 07:43:51 +0200 Subject: [PATCH] Disable take photo option on macOS --- .../Editor/Components/StatusEditorAccessoryView.swift | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/Packages/Status/Sources/Status/Editor/Components/StatusEditorAccessoryView.swift b/Packages/Status/Sources/Status/Editor/Components/StatusEditorAccessoryView.swift index 84f37bae..c99ecf88 100644 --- a/Packages/Status/Sources/Status/Editor/Components/StatusEditorAccessoryView.swift +++ b/Packages/Status/Sources/Status/Editor/Components/StatusEditorAccessoryView.swift @@ -35,10 +35,12 @@ struct StatusEditorAccessoryView: View { } label: { Label("status.editor.photo-library", systemImage: "photo") } - Button { - isCameraPickerPresented = true - } label: { - Label("status.editor.camera-picker", systemImage: "camera") + if !ProcessInfo.processInfo.isiOSAppOnMac { + Button { + isCameraPickerPresented = true + } label: { + Label("status.editor.camera-picker", systemImage: "camera") + } } Button { isFileImporterPresented = true