Skip to content

Commit

Permalink
Load the gui interface after the resource copy is complete.
Browse files Browse the repository at this point in the history
close #69
  • Loading branch information
zhengyangliu committed Nov 30, 2022
1 parent 5018eb7 commit f699337
Showing 1 changed file with 20 additions and 20 deletions.
40 changes: 20 additions & 20 deletions src/main/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -527,26 +527,6 @@ app.on('ready', () => {
});
}

_windows.main = createMainWindow();
_windows.main.on('closed', () => {
delete _windows.main;
});
_windows.about = createAboutWindow();
_windows.about.on('close', event => {
event.preventDefault();
_windows.about.hide();
});
_windows.license = createLicenseWindow();
_windows.license.on('close', event => {
event.preventDefault();
_windows.license.hide();
});
_windows.privacy = createPrivacyWindow();
_windows.privacy.on('close', event => {
event.preventDefault();
_windows.privacy.hide();
});

ipcMain.on('clearCache', () => {
desktopLink.clearCache();
});
Expand All @@ -570,6 +550,26 @@ app.on('ready', () => {
desktopLink.updateCahce();
desktopLink.start()
.then(() => {
_windows.main = createMainWindow();
_windows.main.on('closed', () => {
delete _windows.main;
});
_windows.about = createAboutWindow();
_windows.about.on('close', event => {
event.preventDefault();
_windows.about.hide();
});
_windows.license = createLicenseWindow();
_windows.license.on('close', event => {
event.preventDefault();
_windows.license.hide();
});
_windows.privacy = createPrivacyWindow();
_windows.privacy.on('close', event => {
event.preventDefault();
_windows.privacy.hide();
});

// after finsh load progress show main window and close loading window
_windows.main.show();
_windows.loading.close();
Expand Down

0 comments on commit f699337

Please sign in to comment.