Fix the issue of actors disappearing from system overlay 88/68788/2
authorXiangyin Ma <x1.ma@samsung.com>
Mon, 9 May 2016 16:53:55 +0000 (17:53 +0100)
committerXiangyin Ma <x1.ma@samsung.com>
Tue, 10 May 2016 09:26:47 +0000 (10:26 +0100)
Change-Id: I64372483f68079407b7aadd2e6f602038ac337c0

dali/internal/event/size-negotiation/relayout-controller-impl.cpp

index e380a7e..eebc981 100644 (file)
@@ -31,6 +31,7 @@
 #include <dali/public-api/object/object-registry.h>
 #include <dali/internal/event/actors/actor-impl.h>
 #include <dali/internal/event/common/stage-impl.h>
+#include <dali/internal/event/common/system-overlay-impl.h>
 #include <dali/internal/event/common/thread-local-storage.h>
 
 namespace Dali
@@ -211,9 +212,19 @@ void RelayoutController::OnApplicationSceneCreated()
 
   // Spread the dirty flag through whole tree - don't need to explicity
   // add request on rootLayer as it will automatically be added below.
-  Dali::Actor rootLayer = Dali::Stage::GetCurrent().GetRootLayer();
+  Dali::Stage stage = Dali::Stage::GetCurrent();
+  Dali::Actor rootLayer = stage.GetRootLayer();
   RequestRelayoutTree( rootLayer );
 
+  // Also add request on the root of system overlay
+  Dali::Internal::SystemOverlay* systemOverlay = GetImplementation(stage).GetSystemOverlayInternal();
+  if( systemOverlay )
+  {
+    Dali::Internal::Actor& systemOverlayInternalRoot = systemOverlay->GetDefaultRootActor();
+    Dali::Actor systemOverlayRoot = Dali::Actor(&systemOverlayInternalRoot);
+    RequestRelayoutTree( systemOverlayRoot );
+  }
+
   // Flag request for end of frame
   Request();
 }