Implemented electron integration
This commit is contained in:
parent
513f6ca1c2
commit
bab72e36d0
@ -37,7 +37,7 @@
|
|||||||
"eslint": "7.23.0",
|
"eslint": "7.23.0",
|
||||||
"eslint-config-prettier": "^8.1.0",
|
"eslint-config-prettier": "^8.1.0",
|
||||||
"eslint-plugin-prettier": "3.3.1",
|
"eslint-plugin-prettier": "3.3.1",
|
||||||
"node-sass": "^5.0.0",
|
"node-sass": "^6.0.0",
|
||||||
"npm-run-all": "^4.1.5",
|
"npm-run-all": "^4.1.5",
|
||||||
"postcss": "^8.2.1",
|
"postcss": "^8.2.1",
|
||||||
"prettier": "2.2.1",
|
"prettier": "2.2.1",
|
||||||
|
2724
public/js/bundle.js
2724
public/js/bundle.js
File diff suppressed because one or more lines are too long
@ -68,7 +68,9 @@ function initClient() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
document.addEventListener('DOMContentLoaded', startApp)
|
document.addEventListener('DOMContentLoaded', startApp)
|
||||||
window.addEventListener('pywebviewready', initClient)
|
if (window.api){
|
||||||
|
initClient()
|
||||||
|
}
|
||||||
|
|
||||||
/* ===== Global shortcuts ===== */
|
/* ===== Global shortcuts ===== */
|
||||||
|
|
||||||
|
@ -382,7 +382,7 @@ export default {
|
|||||||
},
|
},
|
||||||
openDownloadsFolder() {
|
openDownloadsFolder() {
|
||||||
// if (this.clientMode) {
|
// if (this.clientMode) {
|
||||||
socket.emit('openDownloadsFolder')
|
window.api.send('openDownloadsFolder')
|
||||||
// }
|
// }
|
||||||
},
|
},
|
||||||
handleDrag(event) {
|
handleDrag(event) {
|
||||||
|
@ -896,14 +896,13 @@ export default {
|
|||||||
socket.on('updateSettings', this.updateSettings)
|
socket.on('updateSettings', this.updateSettings)
|
||||||
socket.on('accountChanged', this.accountChanged)
|
socket.on('accountChanged', this.accountChanged)
|
||||||
socket.on('familyAccounts', this.initAccounts)
|
socket.on('familyAccounts', this.initAccounts)
|
||||||
socket.on('downloadFolderSelected', this.downloadFolderSelected)
|
window.api.receive('downloadFolderSelected', this.downloadFolderSelected)
|
||||||
socket.on('applogin_arl', this.loggedInViaDeezer)
|
window.api.receive('applogin_arl', this.loggedInViaDeezer)
|
||||||
|
|
||||||
this.$on('hook:destroyed', () => {
|
this.$on('hook:destroyed', () => {
|
||||||
socket.off('updateSettings')
|
socket.off('updateSettings')
|
||||||
socket.off('accountChanged')
|
socket.off('accountChanged')
|
||||||
socket.off('familyAccounts')
|
socket.off('familyAccounts')
|
||||||
socket.off('downloadFolderSelected')
|
|
||||||
socket.off('applogin_arl')
|
socket.off('applogin_arl')
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
@ -961,7 +960,7 @@ export default {
|
|||||||
})
|
})
|
||||||
},
|
},
|
||||||
selectDownloadFolder() {
|
selectDownloadFolder() {
|
||||||
socket.emit('selectDownloadFolder')
|
window.api.send('selectDownloadFolder', this.settings.downloadLocation)
|
||||||
},
|
},
|
||||||
downloadFolderSelected(folder) {
|
downloadFolderSelected(folder) {
|
||||||
this.$set(this.settings, 'downloadLocation', folder)
|
this.$set(this.settings, 'downloadLocation', folder)
|
||||||
@ -997,7 +996,7 @@ export default {
|
|||||||
console.log({ response })
|
console.log({ response })
|
||||||
},
|
},
|
||||||
appLogin() {
|
appLogin() {
|
||||||
socket.emit('applogin')
|
window.api.send('applogin')
|
||||||
},
|
},
|
||||||
changeAccount() {
|
changeAccount() {
|
||||||
socket.emit('changeAccount', this.accountNum)
|
socket.emit('changeAccount', this.accountNum)
|
||||||
|
Loading…
Reference in New Issue
Block a user