repo downloading

This commit is contained in:
SpikeHD
2022-05-16 18:56:48 -07:00
parent 3f9aa48bc2
commit 4a559da58c
3 changed files with 78 additions and 4 deletions

View File

@@ -85,7 +85,7 @@ export default class DownloadHandler {
downloadingJar() {
// Kinda hacky but it works
return this.downloads.some(d => d.path.includes('grasscutter'))
return this.downloads.some(d => d.path.includes('grasscutter.zip'))
}
downloadingResources() {
@@ -93,6 +93,10 @@ export default class DownloadHandler {
return this.downloads.some(d => d.path.includes('resources'))
}
downloadingRepo() {
return this.downloads.some(d => d.path.includes('grasscutter_repo.zip'))
}
addDownload(url: string, path: string, onFinish?: () => void) {
// Begin download from rust backend, don't add if the download addition fails
invoke('download_file', { url, path })