Remove unnecessary stage parameter from connnect to stage 22/35122/1
authorKimmo Hoikka <kimmo.hoikka@samsung.com>
Mon, 9 Feb 2015 11:47:23 +0000 (11:47 +0000)
committerKimmo Hoikka <kimmo.hoikka@samsung.com>
Mon, 9 Feb 2015 11:47:23 +0000 (11:47 +0000)
Change-Id: If1c878669227cf0913e7ad6117610dbc4d5f7c3f

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

index a06b19e..0c5f138 100644 (file)
@@ -2108,14 +2108,14 @@ Actor::~Actor()
   delete mAnchorPoint;
 }
 
-void Actor::ConnectToStage( Stage& stage, int index )
+void Actor::ConnectToStage( int index )
 {
   // This container is used instead of walking the Actor hierachy.
   // It protects us when the Actor hierachy is modified during OnStageConnectionExternal callbacks.
   ActorContainer connectionList;
 
   // This stage is atomic i.e. not interrupted by user callbacks
-  RecursiveConnectToStage( stage, connectionList, index );
+  RecursiveConnectToStage( connectionList, index );
 
   // Notify applications about the newly connected actors.
   const ActorIter endIter = connectionList.end();
@@ -2126,7 +2126,7 @@ void Actor::ConnectToStage( Stage& stage, int index )
   }
 }
 
-void Actor::RecursiveConnectToStage( Stage& stage, ActorContainer& connectionList, int index )
+void Actor::RecursiveConnectToStage( ActorContainer& connectionList, int index )
 {
   DALI_ASSERT_ALWAYS( !OnStage() );
 
@@ -2147,7 +2147,7 @@ void Actor::RecursiveConnectToStage( Stage& stage, ActorContainer& connectionLis
     for( ActorIter iter = mChildren->begin(); iter != endIter; ++iter )
     {
       Actor& actor = GetImplementation( *iter );
-      actor.RecursiveConnectToStage( stage, connectionList );
+      actor.RecursiveConnectToStage( connectionList );
     }
   }
 }
@@ -3378,10 +3378,8 @@ void Actor::SetParent(Actor* parent, int index)
     if ( Stage::IsInstalled() && // Don't emit signals or send messages during Core destruction
          parent->OnStage() )
     {
-      StagePtr stage = parent->mStage;
-
       // Instruct each actor to create a corresponding node in the scene graph
-      ConnectToStage(*stage, index);
+      ConnectToStage( index );
     }
   }
   else // parent being set to NULL
index df1bff7..50c58fb 100644 (file)
@@ -1081,16 +1081,15 @@ protected:
    * @param[in] stage The stage.
    * @param[in] index If set, it is only used for positioning the actor within the parent's child list.
    */
-  void ConnectToStage(Stage& stage, int index = -1);
+  void ConnectToStage( int index = -1 );
 
   /**
    * Helper for ConnectToStage, to recursively connect a tree of actors.
    * This is atomic i.e. not interrupted by user callbacks.
-   * @param[in] stage The stage.
    * @param[in] index If set, it is only used for positioning the actor within the parent's child list.
    * @param[out] connectionList On return, the list of connected actors which require notification.
    */
-  void RecursiveConnectToStage( Stage& stage, ActorContainer& connectionList, int index = -1 );
+  void RecursiveConnectToStage( ActorContainer& connectionList, int index = -1 );
 
   /**
    * Connect the Node associated with this Actor to the scene-graph.