Fix the issue that splash screen is displayed late 58/212258/7 accepted/tizen/4.0/unified/20190919.230421 submit/tizen_4.0/20190916.115728
authorjaekuk, lee <juku1999@samsung.com>
Mon, 19 Aug 2019 10:13:00 +0000 (19:13 +0900)
committerjaekuk lee <juku1999@samsung.com>
Mon, 19 Aug 2019 11:59:51 +0000 (11:59 +0000)
Due to 2sec delay timer, splash screen runs after 2sec.
Fix it for splash screen to be displayed without delay
if splash screen is active.

Change-Id: I7b86a68563a87bd06f8f97b19a7f286cb247b1af
Signed-off-by: jaekuk, lee <juku1999@samsung.com>
runtime/browser/splash_screen.h
runtime/browser/web_application.cc

index bde9894..dc43fb3 100755 (executable)
@@ -39,6 +39,7 @@ class SplashScreen {
                std::shared_ptr<const wgt::parse::LaunchScreenInfo> ss_info,
                const std::string& app_path);
   void HideSplashScreen(HideReason reason);
+  bool IsActive() const { return is_active_; }
 
  private:
   std::pair<int, int> GetDimensions(NativeWindow* window);
index 1461b18..b033d31 100755 (executable)
@@ -1561,9 +1561,13 @@ void WebApplication::OnUsermediaPermissionRequest(
 
 void WebApplication::SetTimeoutFirstFrameDelay() {
   LOGGER(DEBUG);
-  firstframe_delay_timer_ = ecore_timer_add(
-    FirstFrameDelayWaitTime,
-    FirstFrameDelayTimerCallback, this);
+  if (splash_screen_->IsActive()) {
+    FirstFrameDelayTimerCallback(this);
+  } else {
+    firstframe_delay_timer_ = ecore_timer_add(
+      FirstFrameDelayWaitTime,
+      FirstFrameDelayTimerCallback, this);
+  }
 }
 
 Eina_Bool WebApplication::FirstFrameDelayTimerCallback(void* data) {