Revert "[Tizen] Revert the change for 0x0 size of the actor"
authorSunghyun Kim <scholb.kim@samsung.com>
Mon, 22 Jun 2020 08:45:24 +0000 (17:45 +0900)
committerSunghyun Kim <scholb.kim@samsung.com>
Mon, 22 Jun 2020 08:45:29 +0000 (17:45 +0900)
This reverts commit 06914168fb473b513bf0a5ca355cc7b5619af810.

Change-Id: I9e8ab172bbf6bea2623b81c399bce78b6abece17

dali/internal/event/actors/actor-impl.cpp

index b89c2fb..5a48d6c 100644 (file)
@@ -4733,12 +4733,12 @@ void Actor::SetPreferredSize( const Vector2& size )
   // A 0 width or height may also be required so if the resize policy has not been changed, i.e. is still set to DEFAULT,
   // then change to FIXED as well
 
-  if( size.width > 0.0f )
+  if( size.width > 0.0f || GetResizePolicy( Dimension::WIDTH ) == ResizePolicy::DEFAULT )
   {
     SetResizePolicy( ResizePolicy::FIXED, Dimension::WIDTH );
   }
 
-  if( size.height > 0.0f )
+  if( size.height > 0.0f || GetResizePolicy( Dimension::HEIGHT ) == ResizePolicy::DEFAULT )
   {
     SetResizePolicy( ResizePolicy::FIXED, Dimension::HEIGHT );
   }