X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=dali%2Finternal%2Fupdate%2Fnodes%2Fnode.cpp;h=189d18cd526e9093164db33459cc9873870c7b94;hb=3ed2e43c4376bc77c56be78849cd00434311966e;hp=d80d7c45fbfd455128c423c2c05a85d04f02761e;hpb=e08e2992259823c5f9832ad959ffa510b0445a6c;p=platform%2Fcore%2Fuifw%2Fdali-core.git diff --git a/dali/internal/update/nodes/node.cpp b/dali/internal/update/nodes/node.cpp index d80d7c4..189d18c 100755 --- a/dali/internal/update/nodes/node.cpp +++ b/dali/internal/update/nodes/node.cpp @@ -79,7 +79,7 @@ void Node::Delete( Node* node ) } Node::Node() -: mTransformManager( NULL ), +: mTransformManager( nullptr ), mTransformId( INVALID_TRANSFORM_ID ), mParentOrigin( TRANSFORM_PROPERTY_PARENT_ORIGIN ), mAnchorPoint( TRANSFORM_PROPERTY_ANCHOR_POINT ), @@ -90,6 +90,7 @@ Node::Node() mVisible( true ), mCulled( false ), mColor( Color::WHITE ), + mUpdateSizeHint( Vector3::ZERO ), mWorldPosition( TRANSFORM_PROPERTY_WORLD_POSITION, Vector3( 0.0f,0.0f,0.0f ) ), // Zero initialized by default mWorldScale( TRANSFORM_PROPERTY_WORLD_SCALE, Vector3( 1.0f,1.0f,1.0f ) ), mWorldOrientation(), // Initialized to identity by default @@ -97,8 +98,8 @@ Node::Node() mWorldColor( Color::WHITE ), mClippingSortModifier( 0u ), mId( ++mNodeCounter ), - mParent( NULL ), - mExclusiveRenderTask( NULL ), + mParent( nullptr ), + mExclusiveRenderTask( nullptr ), mChildren(), mClippingDepth( 0u ), mScissorDepth( 0u ), @@ -222,8 +223,8 @@ void Node::PrepareRender( BufferIndex bufferIndex ) void Node::ConnectChild( Node* childNode ) { DALI_ASSERT_ALWAYS( this != childNode ); - DALI_ASSERT_ALWAYS( IsRoot() || NULL != mParent ); // Parent should be connected first - DALI_ASSERT_ALWAYS( !childNode->IsRoot() && NULL == childNode->GetParent() ); // Child should be disconnected + DALI_ASSERT_ALWAYS( IsRoot() || nullptr != mParent ); // Parent should be connected first + DALI_ASSERT_ALWAYS( !childNode->IsRoot() && nullptr == childNode->GetParent() ); // Child should be disconnected childNode->SetParent( *this ); @@ -243,7 +244,7 @@ void Node::DisconnectChild( BufferIndex updateBufferIndex, Node& childNode ) DALI_ASSERT_ALWAYS( childNode.GetParent() == this ); // Find the childNode and remove it - Node* found( NULL ); + Node* found( nullptr ); const NodeIter endIter = mChildren.End(); for ( NodeIter iter = mChildren.Begin(); iter != endIter; ++iter ) @@ -256,7 +257,7 @@ void Node::DisconnectChild( BufferIndex updateBufferIndex, Node& childNode ) break; // iter is no longer valid } } - DALI_ASSERT_ALWAYS( NULL != found ); + DALI_ASSERT_ALWAYS( nullptr != found ); found->RecursiveDisconnectFromSceneGraph( updateBufferIndex ); } @@ -337,7 +338,7 @@ void Node::SetParent( Node& parentNode ) { DALI_ASSERT_ALWAYS(this != &parentNode); DALI_ASSERT_ALWAYS(!mIsRoot); - DALI_ASSERT_ALWAYS(mParent == NULL); + DALI_ASSERT_ALWAYS(mParent == nullptr); mParent = &parentNode; @@ -350,7 +351,7 @@ void Node::SetParent( Node& parentNode ) void Node::RecursiveDisconnectFromSceneGraph( BufferIndex updateBufferIndex ) { DALI_ASSERT_ALWAYS(!mIsRoot); - DALI_ASSERT_ALWAYS(mParent != NULL); + DALI_ASSERT_ALWAYS(mParent != nullptr); const NodeIter endIter = mChildren.End(); for ( NodeIter iter = mChildren.Begin(); iter != endIter; ++iter ) @@ -362,7 +363,7 @@ void Node::RecursiveDisconnectFromSceneGraph( BufferIndex updateBufferIndex ) PropertyOwner::DisconnectFromSceneGraph( updateBufferIndex ); // Remove back-pointer to parent - mParent = NULL; + mParent = nullptr; // Remove all child pointers mChildren.Clear();