fixed the app selection dialog issue

This commit is contained in:
Shane Harris
2020-10-14 17:58:19 +01:00
parent 602111af4e
commit 6359f11ff9
@@ -305,15 +305,11 @@ export class HeaderComponent implements OnInit {
openDebugger() { openDebugger() {
this.appService.remote.getCurrentWindow().toggleDevTools(); this.appService.remote.getCurrentWindow().toggleDevTools();
} }
selectAppToInstall() { async selectAppToInstall() {
console.log('selectAppToInstall'); let files = await this.appService.electron.remote.dialog.showOpenDialog({
this.appService.electron.remote.dialog.showOpenDialog(
{
properties: ['openFile', 'multiSelections'], properties: ['openFile', 'multiSelections'],
defaultPath: this.adbService.savePath, defaultPath: this.adbService.savePath,
}, });
files => {
console.log('done!');
files.forEach(filepath => { files.forEach(filepath => {
this.adbService.savePath = this.appService.path.dirname(filepath); this.adbService.savePath = this.appService.path.dirname(filepath);
let install = this.adbService.installMultiFile(filepath); let install = this.adbService.installMultiFile(filepath);
@@ -324,8 +320,6 @@ export class HeaderComponent implements OnInit {
} }
}); });
} }
);
}
confirmRestore() { confirmRestore() {
this.spinnerService.showLoader(); this.spinnerService.showLoader();
this.spinnerService.setMessage('Restoring BMBF<br>Please Wait...'); this.spinnerService.setMessage('Restoring BMBF<br>Please Wait...');