mirror of
https://github.com/hydralauncher/hydra.git
synced 2026-01-20 09:43:57 +00:00
Merge branch 'main' into fix/intercepting-cookies
This commit is contained in:
@@ -95,6 +95,11 @@ export function GameOptionsModal({
|
||||
await window.electron.openGameExecutablePath(game.id);
|
||||
};
|
||||
|
||||
const handleClearExecutablePath = async () => {
|
||||
await window.electron.updateExecutablePath(game.id, "");
|
||||
updateGame();
|
||||
};
|
||||
|
||||
const handleChangeWinePrefixPath = async () => {
|
||||
const { filePaths } = await window.electron.showOpenDialog({
|
||||
properties: ["openDirectory"],
|
||||
@@ -106,6 +111,11 @@ export function GameOptionsModal({
|
||||
}
|
||||
};
|
||||
|
||||
const handleClearWinePrefixPath = async () => {
|
||||
await window.electron.selectGameWinePrefix(game.id, "");
|
||||
updateGame();
|
||||
};
|
||||
|
||||
const shouldShowWinePrefixConfiguration =
|
||||
window.electron.platform === "linux";
|
||||
|
||||
@@ -168,6 +178,9 @@ export function GameOptionsModal({
|
||||
<Button onClick={handleCreateShortcut} theme="outline">
|
||||
{t("create_shortcut")}
|
||||
</Button>
|
||||
<Button onClick={handleClearExecutablePath} theme="outline">
|
||||
{t("clear")}
|
||||
</Button>
|
||||
</div>
|
||||
)}
|
||||
|
||||
@@ -196,6 +209,13 @@ export function GameOptionsModal({
|
||||
</Button>
|
||||
}
|
||||
/>
|
||||
{game.winePrefixPath && (
|
||||
<div className={styles.gameOptionRow}>
|
||||
<Button onClick={handleClearWinePrefixPath} theme="outline">
|
||||
{t("clear")}
|
||||
</Button>
|
||||
</div>
|
||||
)}
|
||||
</div>
|
||||
)}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user