Revert "[Tizen] Add mutex to the Adaptor"
authorShinwoo Kim <cinoo.kim@samsung.com>
Wed, 17 Nov 2021 01:51:53 +0000 (10:51 +0900)
committerShinwoo Kim <cinoo.kim@samsung.com>
Wed, 17 Nov 2021 01:51:53 +0000 (10:51 +0900)
This reverts commit 1e4de3afc3301e247f633fc288864a58babb5c07.

dali/internal/adaptor/common/adaptor-impl.cpp
dali/internal/adaptor/common/adaptor-impl.h

index 724848a..e787668 100644 (file)
@@ -295,6 +295,7 @@ void Adaptor::Initialize(GraphicsFactory& graphicsFactory)
     Integration::SetTapMaximumAllowedTime(mEnvironmentOptions->GetTapMaximumAllowedTime());
   }
 
+
   std::string systemCachePath = GetSystemCachePath();
   if(!systemCachePath.empty())
   {
@@ -675,10 +676,7 @@ bool Adaptor::AddWindow(Dali::Integration::SceneHolder childWindow)
   windowImpl.GetRootLayer().SetProperty(Dali::Actor::Property::LAYOUT_DIRECTION, mRootLayoutDirection);
 
   // Add the new Window to the container - the order is not important
-  {
-    Dali::Mutex::ScopedLock lock(mMutex);
-    mWindows.push_back(&windowImpl);
-  }
+  mWindows.push_back(&windowImpl);
 
   Dali::RenderSurfaceInterface* surface = windowImpl.GetSurface();
 
@@ -696,7 +694,6 @@ bool Adaptor::RemoveWindow(Dali::Integration::SceneHolder* childWindow)
   {
     if(*iter == &windowImpl)
     {
-      Dali::Mutex::ScopedLock lock(mMutex);
       mWindows.erase(iter);
       return true;
     }
@@ -711,7 +708,6 @@ bool Adaptor::RemoveWindow(std::string childWindowName)
   {
     if((*iter)->GetName() == childWindowName)
     {
-      Dali::Mutex::ScopedLock lock(mMutex);
       mWindows.erase(iter);
       return true;
     }
@@ -726,7 +722,6 @@ bool Adaptor::RemoveWindow(Internal::Adaptor::SceneHolder* childWindow)
   {
     if((*iter)->GetId() == childWindow->GetId())
     {
-      Dali::Mutex::ScopedLock lock(mMutex);
       mWindows.erase(iter);
       return true;
     }
@@ -821,7 +816,6 @@ Integration::PlatformAbstraction& Adaptor::GetPlatformAbstraction() const
 
 void Adaptor::GetWindowContainerInterface(WindowContainer& windows)
 {
-  Dali::Mutex::ScopedLock lock(mMutex);
   windows = mWindows;
 }
 
@@ -1232,7 +1226,6 @@ Adaptor::Adaptor(Dali::Integration::SceneHolder window, Dali::Adaptor& adaptor,
   mSystemTracer(),
   mObjectProfiler(nullptr),
   mSocketFactory(),
-  mMutex(),
   mThreadMode(threadMode),
   mEnvironmentOptionsOwned(environmentOptions ? false : true /* If not provided then we own the object */),
   mUseRemoteSurface(false),
index 69a6b3f..331ab9a 100644 (file)
@@ -19,7 +19,6 @@
  */
 
 // EXTERNAL INCLUDES
-#include <dali/devel-api/threading/mutex.h>
 #include <dali/integration-api/render-controller.h>
 #include <dali/public-api/common/vector-wrapper.h>
 #include <dali/public-api/math/rect.h>
@@ -680,7 +679,6 @@ private:                                          // Data
   SystemTrace                 mSystemTracer;                          ///< System tracer
   ObjectProfiler*             mObjectProfiler;                        ///< Tracks object lifetime for profiling
   SocketFactory               mSocketFactory;                         ///< Socket factory
-  Mutex                       mMutex;                                 ///< Mutex
   ThreadMode                  mThreadMode;                            ///< The thread mode
   const bool                  mEnvironmentOptionsOwned : 1;           ///< Whether we own the EnvironmentOptions (and thus, need to delete it)
   bool                        mUseRemoteSurface : 1;                  ///< whether the remoteSurface is used or not