Wait for LensApp to report that the view has loaded before showing main window (#2597)

Signed-off-by: Sebastian Malton <sebastian@malton.name>
This commit is contained in:
Sebastian Malton authored and GitHub committed 2021-06-07 08:39:38 -04:00
1 parent 88de530913
commit f3b38d36c6
3 files changed
+49 -19

No files matched your search

+2 -2
View File
@@ -188,7 +188,7 @@ app.on("ready", async () => {
installDeveloperTools();
if (!startHidden) {
windowManager.initMainWindow();
windowManager.ensureMainWindow();
}
ipcMain.on(IpcRendererNavigationEvents.LOADED, () => {
@@ -236,7 +236,7 @@ app.on("activate", (event, hasVisibleWindows) => {
logger.info("APP:ACTIVATE", { hasVisibleWindows });
if (!hasVisibleWindows) {
WindowManager.getInstance(false)?.initMainWindow(false);
WindowManager.getInstance(false)?.ensureMainWindow(false);
}
});