diff options
author | Jan <sentrycraft123@gmail.com> | 2023-07-18 14:26:20 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-07-18 14:26:20 +0200 |
commit | 9dccdb0b0335f82aa9f2e63642f16ff0f2699528 (patch) | |
tree | 22c4651dd5cafc4375e4cd2a76dccf5e389388c5 /src-vue/src | |
parent | dfa5af1746546d388a85081fae499c28521a20ea (diff) | |
download | FlightCore-9dccdb0b0335f82aa9f2e63642f16ff0f2699528.tar.gz FlightCore-9dccdb0b0335f82aa9f2e63642f16ff0f2699528.zip |
feat: Add basic Proton management (#383)
Adds logic to install, remove, and check existing install of NorthstarProton.
Diffstat (limited to 'src-vue/src')
-rw-r--r-- | src-vue/src/views/DeveloperView.vue | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/src-vue/src/views/DeveloperView.vue b/src-vue/src/views/DeveloperView.vue index 500c9c35..28ab3892 100644 --- a/src-vue/src/views/DeveloperView.vue +++ b/src-vue/src/views/DeveloperView.vue @@ -21,6 +21,18 @@ Check NSProton Compatibility </el-button> + <el-button type="primary" @click="installNSProton"> + Install NSProton + </el-button> + + <el-button type="primary" @click="uninstallNSProton"> + Remove NSProton + </el-button> + + <el-button type="primary" @click="getLocalNSProtonVersion"> + Get local NSProton Version + </el-button> + <h3>Testing:</h3> <el-button type="primary" @click="launchGameWithoutChecks"> @@ -308,6 +320,22 @@ export default defineComponent({ notification.close(); }); }, + async installNSProton() { + showNotification(`Started NSProton install`); + await invoke("install_northstar_proton_wrapper") + .then((message) => { showNotification(`Done`); }) + .catch((error) => { showNotification(`Error`, error, "error"); }) + }, + async uninstallNSProton() { + await invoke("uninstall_northstar_proton_wrapper") + .then((message) => { showNotification(`Done`); }) + .catch((error) => { showNotification(`Error`, error, "error"); }) + }, + async getLocalNSProtonVersion() { + await invoke("get_local_northstar_proton_wrapper_version") + .then((message) => { showNotification(`NSProton Version`, message as string); }) + .catch((error) => { showNotification(`Error`, error, "error"); }) + }, } }); </script> |