From: SangYong Park Date: Wed, 10 Apr 2019 06:19:22 +0000 (+0900) Subject: Ignore multiple ready-to-show event X-Git-Tag: submit/tizen/20190412.025133~5 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=e36ea90ac67230d7fdacd5056ddb15038e03f78c;p=platform%2Fframework%2Fweb%2Fwrtjs.git Ignore multiple ready-to-show event ready-to-show event is occurred when web page is first rendered. but, multiple ready-to-show event shows web page in preload mode. Change-Id: I134f02fe1ce3acc31880c7e0c2d4c19abd233c1f Signed-off-by: SangYong Park --- diff --git a/wrt_app/src/web_application.js b/wrt_app/src/web_application.js index b9c9e3a1..e4e96762 100755 --- a/wrt_app/src/web_application.js +++ b/wrt_app/src/web_application.js @@ -60,6 +60,8 @@ class WebApplication { handleEvents(options) { var self = this; this.mainWindow.on('ready-to-show', function() { + if (self.firstRendered) + return; console.log('mainWindow ready-to-show'); wrt.hideSplashScreen(1); self.firstRendered = true;