From 2bcf52209eac1347d78f40fd9df43857650ac2e7 Mon Sep 17 00:00:00 2001 From: Fredrik Burmester Date: Sun, 1 Feb 2026 14:38:35 +0100 Subject: [PATCH] refactor(tv): remove native tv-player-controls module usage --- app/(auth)/player/direct-player.tsx | 116 ++++++++-------------------- 1 file changed, 31 insertions(+), 85 deletions(-) diff --git a/app/(auth)/player/direct-player.tsx b/app/(auth)/player/direct-player.tsx index f210ed95..49fc16b6 100644 --- a/app/(auth)/player/direct-player.tsx +++ b/app/(auth)/player/direct-player.tsx @@ -43,10 +43,6 @@ import { type MpvPlayerViewRef, type MpvVideoSource, } from "@/modules"; -import { - isNativeTVControlsAvailable, - TVPlayerControlsView, -} from "@/modules/tv-player-controls"; import { useDownload } from "@/providers/DownloadProvider"; import { DownloadedItem } from "@/providers/Downloads/types"; import { useInactivity } from "@/providers/InactivityProvider"; @@ -1193,87 +1189,37 @@ export default function page() { item && !isPipMode && (Platform.isTV ? ( - // TV Controls: Use native SwiftUI controls if enabled and available, otherwise JS controls - settings.useNativeTVControls && - isNativeTVControlsAvailable() ? ( - seek(e.nativeEvent.positionMs)} - onSkipForward={() => { - const newPos = Math.min( - (item.RunTimeTicks ?? 0) / 10000, - progress.value + 30000, - ); - progress.value = newPos; - seek(newPos); - }} - onSkipBackward={() => { - const newPos = Math.max(0, progress.value - 10000); - progress.value = newPos; - seek(newPos); - }} - // Audio/subtitle settings will be handled in future iteration - // These would need the same modal hooks as the JS controls - onBack={() => router.back()} - onVisibilityChange={(e) => - setShowControls(e.nativeEvent.visible) - } - /> - ) : ( - - ) + ) : (