Fix issue that main window is not loaded when reloading app 04/264504/4 submit/tizen/20210924.160020
authorjaekuk, lee <juku1999@samsung.com>
Thu, 23 Sep 2021 07:52:34 +0000 (16:52 +0900)
committerjaekuk, lee <juku1999@samsung.com>
Fri, 24 Sep 2021 05:54:58 +0000 (14:54 +0900)
If resuming app that opened more than 3 windows in apps launcher screen,
only one window is removed from window list.

This patch removes all windows except main window when reloading app.

Change-Id: I3059f2007889a04ccbf8fa7591e85241989fba7a
Signed-off-by: jaekuk, lee <juku1999@samsung.com>
wrt_app/src/web_application.ts [changed mode: 0644->0755]

old mode 100644 (file)
new mode 100755 (executable)
index 4d4872a..eb6bc2d
@@ -410,7 +410,7 @@ export class WebApplication {
 
   private closeWindows() {
     this.profileDelegate.clearSuface(this.mainWindow.webContents);
-    this.windowList.forEach((window) => {
+    this.windowList.slice().forEach((window) => {
       if (window != this.mainWindow)
         window.destroy();
     });