diff options
| author | xXJSONDeruloXx <danielhimebauch@gmail.com> | 2026-09-06 00:16:19 -0400 |
|---|---|---|
| committer | xXJSONDeruloXx <danielhimebauch@gmail.com> | 2026-09-06 00:22:35 -0400 |
| commit | a9fd67d05d6819a839a60b581c1dc6eb2792a9be (patch) | |
| tree | 1d3537c24875ef4582039610f68c0831c66307e4 /src/hooks/useLsfgHooks.ts | |
| parent | f9352694a78a2bcfd00d237398a2b30de14c70be (diff) | |
| download | decky-lsfg-vk-a9fd67d05d6819a839a60b581c1dc6eb2792a9be.tar.gz decky-lsfg-vk-a9fd67d05d6819a839a60b581c1dc6eb2792a9be.zip | |
refactor: make Steam branch integration read-only
Diffstat (limited to 'src/hooks/useLsfgHooks.ts')
| -rw-r--r-- | src/hooks/useLsfgHooks.ts | 32 |
1 files changed, 0 insertions, 32 deletions
diff --git a/src/hooks/useLsfgHooks.ts b/src/hooks/useLsfgHooks.ts index dfbf2cd..ea8b3d0 100644 --- a/src/hooks/useLsfgHooks.ts +++ b/src/hooks/useLsfgHooks.ts @@ -3,10 +3,8 @@ import { checkLsfgVkInstalled, getLsfgConfig, getLosslessScalingBranchStatus, - selectLosslessScalingBranch, updateLsfgConfigFromObject, type ConfigUpdateResult, - type SteamBranchOperationResult, type SteamBranchStatus } from "../api/lsfgApi"; import { ConfigurationData, getDefaults } from "../config/configSchema"; @@ -18,7 +16,6 @@ export function useInstallationStatus() { const [losslessScalingInstalled, setLosslessScalingInstalled] = useState<boolean>(false); const [losslessScalingStatus, setLosslessScalingStatus] = useState<string>(""); const [steamBranchStatus, setSteamBranchStatus] = useState<SteamBranchStatus | null>(null); - const [isSwitchingSteamBranch, setIsSwitchingSteamBranch] = useState<boolean>(false); const checkInstallation = async () => { try { @@ -48,33 +45,6 @@ export function useInstallationStatus() { } }; - const selectLosslessScalingBranchForUser = async (): Promise<SteamBranchOperationResult> => { - setIsSwitchingSteamBranch(true); - try { - const result = await selectLosslessScalingBranch(); - setSteamBranchStatus(result); - return result; - } catch (error) { - const result: SteamBranchOperationResult = { - success: false, - message: "", - error: String(error), - installed: false, - manifest_path: undefined, - selected_branch: undefined, - current_branch: undefined, - target_branch: "lsfg-vk", - needs_switch: false, - restart_required: false, - changed: false - }; - setSteamBranchStatus(result); - return result; - } finally { - setIsSwitchingSteamBranch(false); - } - }; - useEffect(() => { checkInstallation(); }, []); @@ -87,8 +57,6 @@ export function useInstallationStatus() { losslessScalingInstalled, losslessScalingStatus, steamBranchStatus, - isSwitchingSteamBranch, - selectLosslessScalingBranch: selectLosslessScalingBranchForUser, checkInstallation }; } |
