From: Tom Robinson Date: Tue, 14 Jul 2015 17:13:00 +0000 (+0100) Subject: Removal of Actor::Insert API X-Git-Tag: dali_1.0.49~3 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=refs%2Fchanges%2F66%2F43866%2F1;p=platform%2Fcore%2Fuifw%2Fdali-demo.git Removal of Actor::Insert API Change-Id: I8940fb262a864c17942615c37229cb154f955486 --- diff --git a/examples/cluster/cluster-example.cpp b/examples/cluster/cluster-example.cpp index 7246878..0bc4532 100644 --- a/examples/cluster/cluster-example.cpp +++ b/examples/cluster/cluster-example.cpp @@ -456,8 +456,8 @@ public: // fitting it inside a quarter of the stage area with the conservative BOX // filter mode: Image bg = ResourceImage::New( CLUSTER_BACKGROUND_IMAGE_PATH, Dali::ImageDimensions( stageSize.x * 0.5f, stageSize.y * 0.5f ), Dali::FittingMode::SHRINK_TO_FIT, Dali::SamplingMode::BOX ); - ImageActor image = ImageActor::New(bg); - clusterActor.SetBackgroundImage(image); + Control clusterControl = Control::DownCast( clusterActor ); + clusterControl.SetBackgroundImage( bg ); // Add actors (pictures) as the children of the cluster for (unsigned int i = 0; (i < style.GetMaximumNumberOfChildren()) && (*paths); i++, paths++) diff --git a/examples/cluster/cluster-impl.cpp b/examples/cluster/cluster-impl.cpp index 3092b7c..ea54014 100644 --- a/examples/cluster/cluster-impl.cpp +++ b/examples/cluster/cluster-impl.cpp @@ -374,23 +374,6 @@ void Cluster::RestoreChild( unsigned int index, AlphaFunction alpha, const TimeP } } -void Cluster::SetBackgroundImage( Actor image ) -{ - // Replaces the background image. - if(mBackgroundImage && mBackgroundImage.GetParent()) - { - mBackgroundImage.GetParent().Remove(mBackgroundImage); - } - - mBackgroundImage = image; - Self().Add(mBackgroundImage); - - mBackgroundImage.SetAnchorPoint( AnchorPoint::TOP_LEFT ); - mBackgroundImage.SetParentOrigin( ParentOrigin::TOP_LEFT ); - - UpdateBackground(0.0f); -} - void Cluster::SetTitle( Actor text ) { // Replaces the title actor. diff --git a/examples/cluster/cluster-impl.h b/examples/cluster/cluster-impl.h index a81a5ea..cf3837c 100644 --- a/examples/cluster/cluster-impl.h +++ b/examples/cluster/cluster-impl.h @@ -156,11 +156,6 @@ public: void RestoreChild( unsigned int index, AlphaFunction alpha, const TimePeriod& period, bool front ); /** - * @copydoc Demo::Cluster::SetBackgroundImage - */ - void SetBackgroundImage( Actor image ); - - /** * @copydoc Demo::Cluster::SetTitle */ void SetTitle( Actor text ); diff --git a/examples/cluster/cluster.cpp b/examples/cluster/cluster.cpp index 76b8cf6..3706301 100644 --- a/examples/cluster/cluster.cpp +++ b/examples/cluster/cluster.cpp @@ -127,11 +127,6 @@ void Cluster::RestoreChild( unsigned int index, AlphaFunction alpha, const TimeP GetImpl(*this).RestoreChild( index, alpha, period, front ); } -void Cluster::SetBackgroundImage( Actor image ) -{ - GetImpl(*this).SetBackgroundImage(image); -} - void Cluster::SetTitle( Actor text ) { GetImpl(*this).SetTitle(text); diff --git a/examples/cluster/cluster.h b/examples/cluster/cluster.h index 07a08dc..090e230 100644 --- a/examples/cluster/cluster.h +++ b/examples/cluster/cluster.h @@ -206,12 +206,6 @@ public: void RestoreChild( unsigned int index, AlphaFunction alpha, const TimePeriod& period, bool front = false ); /** - * Sets the background image. - * @param[in] image The background image. - */ - void SetBackgroundImage( Actor image ); - - /** * Sets the title. * * @param[in] text Title text. diff --git a/resources/scripts/table-view.json b/resources/scripts/table-view.json index 28a370c..f43a8a5 100644 --- a/resources/scripts/table-view.json +++ b/resources/scripts/table-view.json @@ -44,7 +44,6 @@ "type":"TableView", "background-color": [0.5,0.5,0,1], "parent-origin": "CENTER", - "draw-mode": "OVERLAY_2D", "size":[400,400,1], "rows": 4, "columns": 4,