From e6efa4f0ff32d520982860180a29472068aab8e2 Mon Sep 17 00:00:00 2001 From: xXJSONDeruloXx Date: Thu, 10 Sep 2026 09:53:55 -0400 Subject: simplify unhooked game behavior on mount --- src/components/NowPlayingTab.tsx | 42 ++++++---------------------------------- 1 file changed, 6 insertions(+), 36 deletions(-) (limited to 'src/components/NowPlayingTab.tsx') diff --git a/src/components/NowPlayingTab.tsx b/src/components/NowPlayingTab.tsx index 5bce5c4..57858db 100644 --- a/src/components/NowPlayingTab.tsx +++ b/src/components/NowPlayingTab.tsx @@ -11,7 +11,6 @@ interface Props { fieldName: keyof ConfigurationData, value: boolean | number | string | string[], ) => Promise; - onEnable: (appid: string) => Promise; onRepair: (appid: string) => Promise; } @@ -24,25 +23,13 @@ export function NowPlayingTab({ game, config, onConfigChange, - onEnable, onRepair, }: Props) { const [busy, setBusy] = useState(false); const supportNeedsRepair = - game.configured && game.transport.kind === "flatpak" && game.flatpakSupport?.support_status !== "ready"; - const handleEnable = async () => { - if (busy) return; - setBusy(true); - try { - await onEnable(game.appid); - } finally { - setBusy(false); - } - }; - const handleRepair = async () => { if (busy) return; setBusy(true); @@ -60,22 +47,7 @@ export function NowPlayingTab({ - {!game.configured && ( - - - - - - void handleEnable()}> - {busy ? "Enabling..." : "Enable LSFG-VK"} - - - - )} - {game.configured && supportNeedsRepair && ( + {supportNeedsRepair && ( )} - {game.configured && ( - - )} + ); } -- cgit v1.2.3