Size negotiation patch 4: Remove SetRelayoutEnabled 79/38279/5
authorKingsley Stephens <k.stephens@samsung.com>
Tue, 14 Apr 2015 13:01:16 +0000 (14:01 +0100)
committerKingsley Stephens <k.stephens@samsung.com>
Mon, 20 Apr 2015 10:59:48 +0000 (03:59 -0700)
Change-Id: I75c664598c9c1d25c491ed67c35e08dd33bf96f6

17 files changed:
demo/dali-table-view.cpp
examples/blocks/blocks-example.cpp
examples/builder/examples.cpp
examples/buttons/buttons-example.cpp
examples/cluster/cluster-example.cpp
examples/cube-transition-effect/cube-transition-effect-example.cpp
examples/dissolve-effect/dissolve-effect-example.cpp
examples/image-scaling-irregular-grid/image-scaling-irregular-grid-example.cpp
examples/item-view/item-view-example.cpp
examples/magnifier/magnifier-example.cpp
examples/page-turn-view/page-turn-view-example.cpp
examples/path-animation/path-animation.cpp
examples/radial-menu/radial-sweep-view-impl.cpp
examples/scroll-view/scroll-view-example.cpp
examples/shadow-bone-lighting/shadow-bone-lighting-example.cpp
resources/scripts/timing.json
shared/view.h

index 847dddd..c1b7f6b 100644 (file)
@@ -123,21 +123,21 @@ const float IMAGE_BORDER_BOTTOM = IMAGE_BORDER_LEFT;
 struct AnimateBubbleConstraint
 {
 public:
-  AnimateBubbleConstraint( const Vector3& initialPos, float scale, float size )
+  AnimateBubbleConstraint( const Vector3& initialPos, float scale )
       : mInitialX( initialPos.x ),
-        mScale( scale ),
-        mShapeSize( size )
+        mScale( scale )
   {
   }
 
   void operator()( Vector3& position, const PropertyInputContainer& inputs )
   {
     const Vector3& parentSize = inputs[1]->GetVector3();
+    const Vector3& childSize = inputs[2]->GetVector3();
 
     // Wrap bubbles verically.
-    if( position.y + mShapeSize * 0.5f < -parentSize.y * 0.5f )
+    if( position.y + childSize.y * 0.5f < -parentSize.y * 0.5f )
     {
-      position.y = parentSize.y * 0.5f + mShapeSize * 0.5f;
+      position.y = parentSize.y * 0.5f + childSize.y * 0.5f;
     }
 
     // Bubbles X position moves parallax to horizontal
@@ -267,7 +267,6 @@ void DaliTableView::Initialize( Application& application )
 
   // scrollview occupying the majority of the screen
   mScrollView = ScrollView::New();
-  mScrollView.SetRelayoutEnabled( true );
 
   mScrollView.SetAnchorPoint( AnchorPoint::CENTER );
   mScrollView.SetParentOrigin( ParentOrigin::CENTER );
@@ -297,7 +296,6 @@ void DaliTableView::Initialize( Application& application )
 
   // Populate background and bubbles - needs to be scrollViewLayer so scroll ends show
   Actor bubbleContainer = Actor::New();
-  bubbleContainer.SetRelayoutEnabled( true );
   bubbleContainer.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::ALL_DIMENSIONS );
   bubbleContainer.SetAnchorPoint( AnchorPoint::CENTER );
   bubbleContainer.SetParentOrigin( ParentOrigin::CENTER );
@@ -492,7 +490,6 @@ Actor DaliTableView::CreateTile( const std::string& name, const std::string& tit
   content.SetName( name );
   content.SetAnchorPoint( AnchorPoint::CENTER );
   content.SetParentOrigin( ParentOrigin::CENTER );
-  content.SetRelayoutEnabled( true );
   content.SetResizePolicy( ResizePolicy::SIZE_RELATIVE_TO_PARENT, Dimension::ALL_DIMENSIONS );
   content.SetSizeModeFactor( sizeMultiplier );
 
@@ -746,19 +743,18 @@ void DaliTableView::InitialiseBackgroundActors( Actor actor )
   {
     Actor child = actor.GetChildAt( i );
 
-    const Vector3 childSize = child.GetTargetSize();
-
     // Calculate a random position
     Vector3 childPos( Random::Range( -size.x * 0.5f * BACKGROUND_SPREAD_SCALE, size.x * 0.5f * BACKGROUND_SPREAD_SCALE ),
-                      Random::Range( -size.y * 0.5f - childSize.height, size.y * 0.5f + childSize.height ),
+                      Random::Range( -size.y, size.y ),
                       Random::Range( BUBBLE_MIN_Z, BUBBLE_MAX_Z ) );
 
     child.SetPosition( childPos );
 
     // Define bubble horizontal parallax and vertical wrapping
-    Constraint animConstraint = Constraint::New < Vector3 > ( child, Actor::Property::POSITION, AnimateBubbleConstraint( childPos, Random::Range( -0.85f, 0.25f ), childSize.height ) );
+    Constraint animConstraint = Constraint::New < Vector3 > ( child, Actor::Property::POSITION, AnimateBubbleConstraint( childPos, Random::Range( -0.85f, 0.25f ) ) );
     animConstraint.AddSource( Source( mScrollView, ScrollView::Property::SCROLL_POSITION ) );
     animConstraint.AddSource( Dali::ParentSource( Dali::Actor::Property::SIZE ) );
+    animConstraint.AddSource( Dali::LocalSource( Dali::Actor::Property::SIZE ) );
     animConstraint.Apply();
 
     // Kickoff animation
@@ -779,7 +775,6 @@ void DaliTableView::AddBackgroundActors( Actor layer, int count, BufferImage dis
     Vector4 randColour( hue, hue * 0.5, 0.0f, Random::Range( 0.3f, 0.6f ));
 
     ImageActor dfActor = ImageActor::New( distanceField );
-    dfActor.SetRelayoutEnabled( false );
     dfActor.SetSize( Vector2( randSize, randSize ) );
     dfActor.SetParentOrigin( ParentOrigin::CENTER );
 
@@ -885,7 +880,7 @@ void DaliTableView::PauseAnimation()
     {
       Animation anim = *animIter;
 
-      anim.Pause();
+      anim.Stop();
     }
 
     mBackgroundAnimsPlaying = false;
@@ -1008,8 +1003,6 @@ void DaliTableView::OnLogoTapped( Dali::Actor actor, const Dali::TapGesture& tap
       mVersionPopup.HideTail();
       mVersionPopup.OutsideTouchedSignal().Connect( this, &DaliTableView::HideVersionPopup );
       mVersionPopup.HiddenSignal().Connect( this, &DaliTableView::PopupHidden );
-
-      mVersionPopup.MarkDirtyForRelayout();
     }
 
     mVersionPopup.Show();
index eb64275..f50febc 100644 (file)
@@ -358,8 +358,8 @@ private:
     mLevelContainer = Actor::New();
     mLevelContainer.SetAnchorPoint( AnchorPoint::CENTER );
     mLevelContainer.SetParentOrigin( ParentOrigin::CENTER );
-    mLevelContainer.SetRelayoutEnabled( true );
     mLevelContainer.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::ALL_DIMENSIONS );
+
     mContentLayer.Add( mLevelContainer );
 
     mBrickCount = 0;
@@ -531,7 +531,6 @@ private:
     ImageActor brick = ImageActor::New(img);
     brick.SetParentOrigin(ParentOrigin::TOP_LEFT);
     brick.SetAnchorPoint(AnchorPoint::CENTER);
-    brick.SetRelayoutEnabled( false );
     brick.SetSize( brickSize );
     brick.SetPosition( Vector3( position ) );
 
@@ -563,7 +562,6 @@ private:
     ImageActor actor = ImageActor::New(img);
     actor.SetParentOrigin(ParentOrigin::TOP_LEFT);
     actor.SetAnchorPoint(AnchorPoint::CENTER);
-    actor.SetRelayoutEnabled( false );
     return actor;
   }
 
index 5578d7c..f43ba1e 100644 (file)
@@ -287,7 +287,6 @@ public:
     mFiles.clear();
 
     mItemView = ItemView::New(*this);
-    mItemView.SetRelayoutEnabled( false );
     stage.Add( mItemView );
     mItemView.SetParentOrigin(ParentOrigin::CENTER);
     mItemView.SetAnchorPoint(AnchorPoint::CENTER);
@@ -469,9 +468,6 @@ public:
     }
 
     builder.AddActors( layer );
-
-    // Force relayout on layer
-    layer.RelayoutRequestTree();
   }
 
 
index 88aa86f..f5c035a 100644 (file)
@@ -214,8 +214,8 @@ class ButtonsController: public ConnectionTracker
     mBigImage3 = ResourceImage::New( BIG_IMAGE_3 );
 
     mImage = ImageActor::New( mBigImage1 );
-    mImage.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::HEIGHT );
-    mImage.SetResizePolicy( ResizePolicy::DIMENSION_DEPENDENCY, Dimension::WIDTH );
+    mImage.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::ALL_DIMENSIONS );
+    mImage.SetSizeScalePolicy( SizeScalePolicy::FIT_WITH_ASPECT_RATIO );
     radioGroup2Background.AddChild( mImage, Toolkit::TableView::CellPosition( 0, 1, 2, 1 ) );
 
     // The enable/disable radio group
@@ -349,7 +349,6 @@ class ButtonsController: public ConnectionTracker
 
     contentTable.Add( toggleBackground );
 
-
     Toolkit::PushButton toggleButton = Toolkit::PushButton::New();
     toggleButton.SetTogglableButton( true );
     toggleButton.SetLabel( "Unselected" );
index 59af760..e7bf78d 100644 (file)
@@ -477,7 +477,6 @@ public:
 
     // create and setup the scroll view...
     mScrollView = ScrollView::New();
-    mScrollView.SetRelayoutEnabled( false );
     mScrollView.SetSize(stageSize);
 
     // attach Wobble Effect to ScrollView
@@ -489,7 +488,6 @@ public:
     mScrollView.SetParentOrigin(ParentOrigin::CENTER);
 
     // Scale ScrollView to fit parent (mContentLayer)
-    mScrollView.SetRelayoutEnabled( true );
     mScrollView.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::ALL_DIMENSIONS );
 
     // Add the scroll view to the content layer
@@ -511,17 +509,20 @@ public:
   /**
    * Helper to create the cluster actors
    */
-  Cluster CreateClusterActor(ClusterType clusterType, ClusterStyle style)
+  Cluster CreateClusterActor(ClusterType clusterType, ClusterStyle style, Vector3& clusterSize)
   {
     // Create the cluster actor with the given cluster style
     Cluster clusterActor = Cluster::New(style);
     clusterActor.SetParentOrigin(ParentOrigin::CENTER);
     clusterActor.SetAnchorPoint(AnchorPoint::CENTER);
-    clusterActor.SetRelayoutEnabled( false );
 
     Vector2 stageSize = Dali::Stage::GetCurrent().GetSize();
     float minStageDimension = std::min(stageSize.x, stageSize.y);
-    clusterActor.SetSize(minStageDimension * CLUSTER_RELATIVE_SIZE, minStageDimension * CLUSTER_RELATIVE_SIZE, 0.0f);
+
+    clusterSize.x = minStageDimension * CLUSTER_RELATIVE_SIZE;
+    clusterSize.y = minStageDimension * CLUSTER_RELATIVE_SIZE;
+
+    clusterActor.SetSize( clusterSize );
 
     DALI_ASSERT_ALWAYS(clusterType < CLUSTER_COUNT);
     const char **paths = IMAGE_GROUPS[clusterType];
@@ -536,7 +537,6 @@ public:
     backgroundAttributes.SetScalingMode( Dali::ImageAttributes::ShrinkToFit );
     Image bg = ResourceImage::New( CLUSTER_BACKGROUND_IMAGE_PATH );
     ImageActor image = ImageActor::New(bg);
-    image.SetRelayoutEnabled( false );
     clusterActor.SetBackgroundImage(image);
 
     // Add actors (pictures) as the children of the cluster
@@ -629,19 +629,18 @@ public:
     mScrollView.Add(pageView);
     pageView.SetParentOrigin(ParentOrigin::CENTER);
     pageView.SetPosition(Vector3(stageSize.width * column, 0.0f, 0.0f));
-    pageView.SetRelayoutEnabled( true );
     pageView.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::ALL_DIMENSIONS );
 
     // Create cluster actors, add them to scroll view, and set the shear effect with the given center point.
-    Cluster cluster = CreateClusterActor(clusterType, style);
+    Vector3 clusterSize;
+    Cluster cluster = CreateClusterActor( clusterType, style, clusterSize );
     cluster.SetParentOrigin(ParentOrigin::TOP_LEFT);
     cluster.SetAnchorPoint(AnchorPoint::TOP_LEFT);
     cluster.SetPosition( clusterPosition );
 
     pageView.Add(cluster);
-    Vector3 clusterSize = cluster.GetCurrentSize();
 
-    mClusterInfo.push_back(ClusterInfo( cluster, mClusterCount, clusterPosition, clusterSize ));
+    mClusterInfo.push_back( ClusterInfo( cluster, mClusterCount, clusterPosition, clusterSize ) );
 
     mClusterCount++;
   }
index 691fe06..99e4e8c 100644 (file)
@@ -330,7 +330,6 @@ void CubeTransitionApp::GoToNextImage()
   mNextImage.SetPositionInheritanceMode(USE_PARENT_POSITION);
   mNextImage.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::ALL_DIMENSIONS );
   mNextImage.SetSizeScalePolicy( SizeScalePolicy::FIT_WITH_ASPECT_RATIO );
-  mNextImage.SetRelayoutEnabled( false );
   mCurrentEffect.SetTargetImage(mNextImage);
   if( image.GetLoadingState() == ResourceLoadingSucceeded )
   {
index 59da358..8190a1a 100644 (file)
@@ -254,7 +254,6 @@ void DissolveEffectApp::OnInit( Application& application )
 
   // show the first image
   mCurrentImage = ImageActor::New( LoadStageFillingImage( IMAGES[mIndex] ) );
-  mCurrentImage.SetRelayoutEnabled( false );
   mCurrentImage.SetPositionInheritanceMode(USE_PARENT_POSITION_PLUS_LOCAL_POSITION);
   mCurrentImage.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::ALL_DIMENSIONS );
   mCurrentImage.SetSizeScalePolicy( SizeScalePolicy::FIT_WITH_ASPECT_RATIO );
@@ -285,7 +284,6 @@ void DissolveEffectApp::OnPanGesture( Actor actor, const PanGesture& gesture )
 
     Image image = LoadStageFillingImage( IMAGES[ mIndex ] );
     mNextImage = ImageActor::New( image );
-    mNextImage.SetRelayoutEnabled( false );
     mNextImage.SetPositionInheritanceMode(USE_PARENT_POSITION_PLUS_LOCAL_POSITION);
     mNextImage.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::ALL_DIMENSIONS );
     mNextImage.SetSizeScalePolicy( SizeScalePolicy::FIT_WITH_ASPECT_RATIO );
index 8fb6496..a7798ac 100644 (file)
@@ -423,7 +423,6 @@ public:
     // coordinates in a frame defined by a parent actor:
 
     Actor gridActor = Actor::New();
-    gridActor.SetRelayoutEnabled( true );
     gridActor.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::ALL_DIMENSIONS );
     gridActor.SetParentOrigin( ParentOrigin::CENTER );
     gridActor.SetAnchorPoint( AnchorPoint::CENTER );
index a750d4f..9bfbac8 100644 (file)
@@ -314,7 +314,6 @@ public:
     // Create the item view actor
     mImageAtlas = CreateImageAtlas();
     mItemView = ItemView::New(*this);
-    mItemView.SetRelayoutEnabled( false );
     mItemView.SetParentOrigin(ParentOrigin::CENTER);
     mItemView.SetAnchorPoint(AnchorPoint::CENTER);
 
@@ -905,7 +904,6 @@ public: // From ItemFactory
     // Add a checkbox child actor; invisible until edit-mode is enabled
 
     ImageActor checkbox = ImageActor::New( mWhiteImage );
-    checkbox.SetRelayoutEnabled( false );
     checkbox.SetName( "CheckBox" );
     checkbox.SetColor( Vector4(0.0f,0.0f,0.0f,0.6f) );
     checkbox.SetParentOrigin( ParentOrigin::TOP_RIGHT );
@@ -922,7 +920,6 @@ public: // From ItemFactory
     actor.Add( checkbox );
 
     ImageActor tick = ImageActor::New( ResourceImage::New(SELECTED_IMAGE) );
-    tick.SetRelayoutEnabled( false );
     tick.SetColorMode( USE_OWN_COLOR );
     tick.SetName( "Tick" );
     tick.SetParentOrigin( ParentOrigin::TOP_RIGHT );
@@ -1010,7 +1007,6 @@ private:
     slider.Add( text );
 
     Actor textContainer = Actor::New();
-    textContainer.SetRelayoutEnabled( true );
     textContainer.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::ALL_DIMENSIONS );
     mAlphaFunctionText = TextLabel::New( ALPHA_FUNCTIONS_TEXT[mAlphaFuncIndex] );
     mAlphaFunctionText.SetAnchorPoint( ParentOrigin::CENTER );
@@ -1029,7 +1025,6 @@ private:
     text.SetSize( 0.0f, LABEL_TEXT_SIZE_Y );
     textContainer.Add( text );
 
-    mMenu.MarkDirtyForRelayout();
     mMenu.Show();
     mMenuShown = true;
   }
index 4c8ea21..791935d 100644 (file)
@@ -219,14 +219,12 @@ public:
 
     // Create magnifier (controlled by human touch)
     Layer overlay = Layer::New();
-    overlay.SetRelayoutEnabled( false );
     overlay.SetSensitive(false);
     overlay.SetParentOrigin( ParentOrigin::CENTER );
     overlay.SetSize(mStageSize);
     Stage::GetCurrent().Add(overlay);
 
     mMagnifier = Toolkit::Magnifier::New();
-    mMagnifier.SetRelayoutEnabled( false );
     mMagnifier.SetSourceActor( mView.GetBackgroundLayer() );
     mMagnifier.SetSize( MAGNIFIER_SIZE * mStageSize.width );  // Size of magnifier is in relation to stage width
     mMagnifier.SetMagnificationFactor( MAGNIFICATION_FACTOR );
@@ -234,7 +232,7 @@ public:
     overlay.Add( mMagnifier );
 
     // Apply constraint to animate the position of the magnifier.
-    Constraint constraint = Constraint::New<Vector3>( mMagnifier, Actor::Property::POSITION, ConfinementConstraint(ParentOrigin::CENTER, Vector2::ONE * MAGNIFIER_INDENT, Vector2::ONE * MAGNIFIER_INDENT) );
+    Constraint constraint = Constraint::New<Vector3>( mMagnifier, Actor::Property::POSITION, ConfinementConstraint(Vector3( 0.5f, 0.5f, 0.0f ), Vector2::ONE * MAGNIFIER_INDENT, Vector2::ONE * MAGNIFIER_INDENT) );
     constraint.AddSource( LocalSource(Actor::Property::SIZE) );
     constraint.AddSource( LocalSource(Actor::Property::PARENT_ORIGIN) );
     constraint.AddSource( LocalSource(Actor::Property::ANCHOR_POINT) );
@@ -244,7 +242,6 @@ public:
 
     // Create bouncing magnifier automatically bounces around screen.
     mBouncingMagnifier = Toolkit::Magnifier::New();
-    mBouncingMagnifier.SetRelayoutEnabled( false );
     mBouncingMagnifier.SetSourceActor( mView.GetBackgroundLayer() );
     mBouncingMagnifier.SetSize( MAGNIFIER_SIZE * mStageSize.width ); // Size of magnifier is in relation to stage width
     mBouncingMagnifier.SetMagnificationFactor( MAGNIFICATION_FACTOR );
index 33498cd..a57b9f4 100644 (file)
@@ -91,8 +91,6 @@ class PortraitPageFactory : public PageFactory
       page = ImageActor::New( ResourceImage::New( PAGE_IMAGES_PORTRAIT[ (pageId-1) % NUMBER_OF_PORTRAIT_IMAGE ] ) );
     }
 
-    page.SetRelayoutEnabled( false );
-
     return page;
   }
 };
@@ -129,9 +127,6 @@ class LandscapePageFactory : public PageFactory
     }
     pageFront.Add(pageBack);
 
-    pageFront.SetRelayoutEnabled( false );
-    pageBack.SetRelayoutEnabled( false );
-
     return pageFront;
   }
 };
@@ -237,7 +232,6 @@ void PageTurnController::OnInit( Application& app )
 
   // Create default View.
   mView = View::New();
-  mView.SetRelayoutEnabled( false );
   stage.Add( mView );
 
   Dali::Window winHandle = app.GetWindow();
@@ -251,7 +245,6 @@ void PageTurnController::OnInit( Application& app )
   mView.OrientationAnimationStartedSignal().Connect( this, &PageTurnController::OnOrientationAnimationStarted );
 
   mPageTurnPortraitView = PageTurnPortraitView::New( mPortraitPageFactory, stageSize );
-  mPageTurnPortraitView.SetRelayoutEnabled( false );
   mPageTurnPortraitView.SetSpineShadowParameter( Vector2(70.f, 30.f) );
   mPageTurnPortraitView.PageTurnStartedSignal().Connect( this, &PageTurnController::OnPageStartedTurn );
   mPageTurnPortraitView.PageTurnFinishedSignal().Connect( this, &PageTurnController::OnPageFinishedTurn );
@@ -260,7 +253,6 @@ void PageTurnController::OnInit( Application& app )
   mPageTurnPortraitView.SetPositionInheritanceMode( USE_PARENT_POSITION );
 
   mPageTurnLandscapeView = PageTurnLandscapeView::New( mLandscapePageFactory, Vector2(stageSize.y*0.5f, stageSize.x) );
-  mPageTurnLandscapeView.SetRelayoutEnabled( false );
   mPageTurnLandscapeView.PageTurnStartedSignal().Connect( this, &PageTurnController::OnPageStartedTurn );
   mPageTurnLandscapeView.PageTurnFinishedSignal().Connect( this, &PageTurnController::OnPageFinishedTurn );
   mPageTurnLandscapeView.PagePanStartedSignal().Connect( this, &PageTurnController::OnPageStartedPan );
index 18c5140..daf672c 100644 (file)
@@ -70,7 +70,6 @@ public:
     text.SetColor( Vector4(0.0f,0.0f,0.0f,1.0f));
 
     Slider slider = Slider::New();
-    slider.SetRelayoutEnabled( false );
     slider.SetAnchorPoint( AnchorPoint::CENTER_LEFT);
     slider.SetParentOrigin( ParentOrigin::CENTER_RIGHT);
     slider.SetProperty(Slider::Property::LOWER_BOUND, -1.0f );
@@ -102,8 +101,8 @@ public:
 
     //TextInput
     Dali::Layer controlsLayer = Dali::Layer::New();
-    controlsLayer.SetRelayoutEnabled( false );
-    controlsLayer.SetSize( stage.GetSize().x, stage.GetSize().y*0.3f, 0.0 );
+    controlsLayer.SetResizePolicy( ResizePolicy::SIZE_RELATIVE_TO_PARENT, Dimension::ALL_DIMENSIONS );
+    controlsLayer.SetSizeModeFactor( Vector3( 1.0f, 0.3f, 1.0f ) );
     controlsLayer.SetPosition( 0.0f, stage.GetSize().y*0.8f, 0.0f );
     controlsLayer.SetAnchorPoint( AnchorPoint::TOP_LEFT);
     controlsLayer.SetParentOrigin( ParentOrigin::TOP_LEFT);
@@ -202,7 +201,6 @@ public:
       if( !mControlPoint[index] )
       {
         mControlPoint[index] = Toolkit::CreateSolidColorActor(Vector4(1.0f,1.0f,1.0f,1.0f));
-        mControlPoint[index].SetRelayoutEnabled( false );
         mControlPoint[index].SetParentOrigin( ParentOrigin::TOP_LEFT);
         mControlPoint[index].SetAnchorPoint( AnchorPoint::CENTER );
         mControlPoint[index].SetSize( 20.0f, 20.0f );
@@ -224,7 +222,6 @@ public:
       if( !mControlPoint[index])
       {
         mControlPoint[index] = Toolkit::CreateSolidColorActor(Vector4(1.0f,1.0f,1.0f,1.0f));
-        mControlPoint[index].SetRelayoutEnabled( false );
         mControlPoint[index].SetParentOrigin( ParentOrigin::TOP_LEFT);
         mControlPoint[index].SetAnchorPoint( AnchorPoint::CENTER );
         mControlPoint[index].SetSize( 20.0f, 20.0f );
@@ -473,7 +470,6 @@ public:
     ImageAttributes attributes;
     Image img = ResourceImage::New(ACTOR_IMAGE, attributes );
     mActor = ImageActor::New( img );
-    mActor.SetRelayoutEnabled( false );
     mActor.SetAnchorPoint( AnchorPoint::CENTER );
     mActor.SetSize( 100, 50, 1 );
     stage.Add( mActor );
index 50736a2..1062406 100644 (file)
@@ -131,7 +131,7 @@ RadialSweepView RadialSweepViewImpl::New( float duration, float diameter, Degree
 }
 
 RadialSweepViewImpl::RadialSweepViewImpl( float duration, float diameter, Degree initialAngle, Degree finalAngle, Degree initialSector, Degree finalSector )
-: Control( CONTROL_BEHAVIOUR_NONE ),
+: Control( ControlBehaviour( ACTOR_BEHAVIOUR_NONE ) ),
   mDuration(duration),
   mDiameter(diameter),
   mInitialAngle(initialAngle),
index 4fa6c22..27be4a1 100644 (file)
@@ -228,7 +228,6 @@ private:
     Vector2 stageSize = stage.GetSize();
 
     mScrollView = ScrollView::New();
-    mScrollView.SetRelayoutEnabled( false );
     mScrollView.SetAnchorPoint(AnchorPoint::CENTER);
     mScrollView.SetParentOrigin(ParentOrigin::CENTER);
     mContentLayer.Add( mScrollView );
@@ -301,7 +300,6 @@ private:
   Actor CreatePage()
   {
     Actor page = Actor::New();
-    page.SetRelayoutEnabled( true );
     page.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::ALL_DIMENSIONS );
     page.SetParentOrigin( ParentOrigin::CENTER );
     page.SetAnchorPoint( AnchorPoint::CENTER );
@@ -454,7 +452,6 @@ private:
    void ApplyEffectToPage(Actor page)
    {
      page.RemoveConstraints();
-     page.SetRelayoutEnabled( true );
      page.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::ALL_DIMENSIONS );
 
      switch( mEffectMode )
@@ -571,7 +568,6 @@ private:
     attributes.SetFilterMode( ImageAttributes::BoxThenLinear );
     Image img = ResourceImage::New(filename, attributes);
     ImageActor actor = ImageActor::New(img);
-    actor.SetRelayoutEnabled( false );
     actor.SetName( filename );
     actor.SetParentOrigin(ParentOrigin::CENTER);
     actor.SetAnchorPoint(AnchorPoint::CENTER);
index 42f0c0d..4a3ca8a 100644 (file)
@@ -192,7 +192,6 @@ public:
     mShadowView.SetName("Container");
     mShadowView.SetParentOrigin(ParentOrigin::CENTER);
     mShadowView.SetAnchorPoint(AnchorPoint::CENTER);
-    mShadowView.SetRelayoutEnabled( true );
     mShadowView.SetResizePolicy( ResizePolicy::FILL_TO_PARENT, Dimension::ALL_DIMENSIONS );
     mShadowView.SetPointLightFieldOfView( Math::PI / 2.0f);
     mContents.Add(mShadowView);
index a5d8024..e3864f1 100644 (file)
       ]
     },
     {
-      "type": "TextView",
-      "text": "<font size='20' color='#fea011'><b>Touch</b></font>",
-      "markup-enabled": true,
+      "type": "TextLabel",
+      "text": "Touch",
       "name": "Instruction",
       "parent-origin": "BOTTOM_CENTER",
       "anchor-point": "BOTTOM_CENTER",
+      "text-color": [1, 0, 0, 1],
       "position": [
         0,
         0,
index f5fa893..27b1b3e 100644 (file)
@@ -76,8 +76,8 @@ Dali::Layer CreateToolbar( Dali::Toolkit::ToolBar& toolBar,
   toolBarLayer.SetName( "TOOLBAR_LAYER" );
   toolBarLayer.SetAnchorPoint( Dali::AnchorPoint::TOP_CENTER );
   toolBarLayer.SetParentOrigin( Dali::ParentOrigin::TOP_CENTER );
-  toolBarLayer.SetSize( 0.0f, style.mToolBarHeight );
   toolBarLayer.SetResizePolicy( Dali::ResizePolicy::FILL_TO_PARENT, Dali::Dimension::WIDTH );
+  toolBarLayer.SetSize( 0.0f, style.mToolBarHeight );
 
   // Raise tool bar layer to the top.
   toolBarLayer.RaiseToTop();