From b02fbd646d41489d849950d922b7da0c40d999f3 Mon Sep 17 00:00:00 2001 From: "pouria.amini" Date: Tue, 16 Jul 2024 11:31:41 -0700 Subject: [PATCH] fix: exclude unsupported gestures in tvos --- Sources/Amplitude/Plugins/iOS/UIKitUserInteractions.swift | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/Sources/Amplitude/Plugins/iOS/UIKitUserInteractions.swift b/Sources/Amplitude/Plugins/iOS/UIKitUserInteractions.swift index 64377ad..b767386 100644 --- a/Sources/Amplitude/Plugins/iOS/UIKitUserInteractions.swift +++ b/Sources/Amplitude/Plugins/iOS/UIKitUserInteractions.swift @@ -92,12 +92,14 @@ extension UIGestureRecognizer { let gestureType = switch self { case is UITapGestureRecognizer: "Tap" - case is UIPinchGestureRecognizer: "Pinch" - case is UIRotationGestureRecognizer: "Rotation" case is UISwipeGestureRecognizer: "Swipe" case is UIPanGestureRecognizer: "Pan" - case is UIScreenEdgePanGestureRecognizer: "Screen Edge Pan" case is UILongPressGestureRecognizer: "Long Press" +#if !os(tvOS) + case is UIPinchGestureRecognizer: "Pinch" + case is UIRotationGestureRecognizer: "Rotation" + case is UIScreenEdgePanGestureRecognizer: "Screen Edge Pan" +#endif default: "Custom Gesture" }