From: Richard Huang Date: Tue, 19 May 2020 12:46:03 +0000 (+0100) Subject: Remove some public Setter/Getter APIs from Dali::Actor X-Git-Tag: dali_1.9.13~2 X-Git-Url: http://review.tizen.org/git/?p=platform%2Fcore%2Fuifw%2Fdali-adaptor.git;a=commitdiff_plain;h=e3c97a26dc7d9519723c0acfbc38e5f47ecec907 Remove some public Setter/Getter APIs from Dali::Actor Change-Id: I0e4c42f7988b38b82956d628474103c90db0f407 --- diff --git a/automated-tests/src/dali-adaptor/utc-Dali-PixelBuffer.cpp b/automated-tests/src/dali-adaptor/utc-Dali-PixelBuffer.cpp index 709b2c9..055d4be 100644 --- a/automated-tests/src/dali-adaptor/utc-Dali-PixelBuffer.cpp +++ b/automated-tests/src/dali-adaptor/utc-Dali-PixelBuffer.cpp @@ -243,7 +243,7 @@ int UtcDaliPixelBufferConvert(void) Actor a = Actor::New(); a.AddRenderer(r); a.SetSize(10, 10); - a.SetParentOrigin(ParentOrigin::CENTER); + a.SetProperty( Actor::Property::PARENT_ORIGIN, ParentOrigin::CENTER ); Stage::GetCurrent().Add(a); application.SendNotification(); diff --git a/dali/internal/accessibility/tizen-wayland/atspi/accessibility-impl.cpp b/dali/internal/accessibility/tizen-wayland/atspi/accessibility-impl.cpp index 30b9179..382e08b 100644 --- a/dali/internal/accessibility/tizen-wayland/atspi/accessibility-impl.cpp +++ b/dali/internal/accessibility/tizen-wayland/atspi/accessibility-impl.cpp @@ -605,9 +605,9 @@ public: Dali::Rect<> GetExtents( Dali::Accessibility::CoordType ctype ) override { Vector2 screenPosition = actor.GetProperty( Dali::DevelActor::Property::SCREEN_POSITION ).Get< Vector2 >(); - Vector3 size = actor.GetCurrentSize() * actor.GetCurrentWorldScale(); + Vector3 size = actor.GetCurrentProperty< Vector3 >( Actor::Property::SIZE ) * actor.GetCurrentProperty< Vector3 >( Actor::Property::WORLD_SCALE ); bool positionUsesAnchorPoint = actor.GetProperty( Dali::DevelActor::Property::POSITION_USES_ANCHOR_POINT ).Get< bool >(); - Vector3 anchorPointOffSet = size * ( positionUsesAnchorPoint ? actor.GetCurrentAnchorPoint() : AnchorPoint::TOP_LEFT ); + Vector3 anchorPointOffSet = size * ( positionUsesAnchorPoint ? actor.GetCurrentProperty< Vector3 >( Actor::Property::ANCHOR_POINT ) : AnchorPoint::TOP_LEFT ); Vector2 position = Vector2( screenPosition.x - anchorPointOffSet.x, screenPosition.y - anchorPointOffSet.y ); return { position.x, position.y, size.x, size.y }; @@ -646,7 +646,7 @@ public: } std::string GetName() override { - return actor.GetName(); + return actor.GetProperty< std::string >( Dali::Actor::Property::NAME ); } std::string GetDescription() override { diff --git a/dali/internal/network/common/automation.cpp b/dali/internal/network/common/automation.cpp index ce17605..7c5be2b 100644 --- a/dali/internal/network/common/automation.cpp +++ b/dali/internal/network/common/automation.cpp @@ -334,8 +334,8 @@ std::string DumpJson( Dali::Actor actor, int level ) { // All the information about this actor std::ostringstream msg; - msg << "{ " << Quote( "Name" ) << " : " << Quote( actor.GetName() ) << ", " << Quote( "level" ) << " : " << level << ", " << Quote( "id" ) << " : " << actor.GetId() << ", " << Quote( "IsVisible" ) - << " : " << actor.IsVisible() << ", " << Quote( "IsSensitive" ) << " : " << actor.IsSensitive(); + msg << "{ " << Quote( "Name" ) << " : " << Quote( actor.GetProperty< std::string >( Actor::Property::NAME ) ) << ", " << Quote( "level" ) << " : " << level << ", " << Quote( "id" ) << " : " << actor.GetId() << ", " << Quote( "IsVisible" ) + << " : " << actor.GetCurrentProperty< bool >( Actor::Property::VISIBLE ) << ", " << Quote( "IsSensitive" ) << " : " << actor.GetProperty< bool >( Actor::Property::SENSITIVE ); msg << ", " << Quote( "properties" ) << ": [ "; diff --git a/dali/internal/system/common/capture-impl.cpp b/dali/internal/system/common/capture-impl.cpp index 2724dd2..253a3fd 100644 --- a/dali/internal/system/common/capture-impl.cpp +++ b/dali/internal/system/common/capture-impl.cpp @@ -188,8 +188,8 @@ void Capture::SetupRenderTask( Dali::Actor source, const Dali::Vector4& clearCol if( !mCameraActor ) { mCameraActor = Dali::CameraActor::New( stageSize ); - mCameraActor.SetParentOrigin( ParentOrigin::CENTER ); - mCameraActor.SetAnchorPoint( AnchorPoint::CENTER ); + mCameraActor.SetProperty( Dali::Actor::Property::PARENT_ORIGIN, ParentOrigin::CENTER ); + mCameraActor.SetProperty( Dali::Actor::Property::ANCHOR_POINT, AnchorPoint::CENTER ); } stage.Add( mCameraActor );