Prevent window showing during termination 82/257882/1 accepted/tizen/6.0/unified/20210507.075112 submit/tizen_6.0/20210506.083409 submit/tizen_6.0/20210507.004030 submit/tizen_6.0/20210630.053442
authorSangYong Park <sy302.park@samsung.com>
Thu, 6 May 2021 01:31:33 +0000 (10:31 +0900)
committerSangYong Park <sy302.park@samsung.com>
Thu, 6 May 2021 01:31:33 +0000 (10:31 +0900)
Show previous window when current window was closed.
but, window showing causes invalid memory access in termination.
so, prevent window showing during app termination.

Change-Id: I7878594d5ba12b5300523e00262ff84d95072ba7
Signed-off-by: SangYong Park <sy302.park@samsung.com>
wrt_app/src/web_application.ts

index 8888289883582499cefc8c5cd74ea2765725f34a..7c392aa5116effc5c6df77b352c4d140d481c37b 100755 (executable)
@@ -84,7 +84,7 @@ export class WebApplication {
         console.log(`window closed : #${this.windowList.length}`);
         let index = this.windowList.indexOf(window);
         this.windowList.splice(index, 1);
-        if (index === this.windowList.length && this.windowList.length > 0)
+        if (!this.inQuit && index === this.windowList.length && this.windowList.length > 0)
           this.windowList[this.windowList.length - 1].show();
       });
     });