This patch is auto generated by clang-tidy with modernize-use-nullptr check.
Change-Id: Iafb79e884e79ec02ebdf32ea687f519aceb1f4dc
}
}
}
- return NULL;
+ return nullptr;
}
/**
{
return table[value].string;
}
- return NULL;
+ return nullptr;
}
/**
return new Dali::Internal::BitmapCompressed( discardable );
}
}
- return 0;
+ return nullptr;
}
PixelBuffer* Bitmap::GetBufferOwnership()
{
PixelBuffer* buffer = mData;
- mData = NULL;
+ mData = nullptr;
return buffer;
}
return;
}
free ( mData );
- mData = NULL;
+ mData = nullptr;
}
* @param[in] discardable Flag to tell the bitmap if it can delete the buffer with the pixel data.
* @param[in] pixBuf External buffer of pixel data or null.
*/
- Bitmap( ResourcePolicy::Discardable discardable = ResourcePolicy::OWNED_RETAIN, Dali::Integration::PixelBuffer* pixBuf = 0 );
+ Bitmap( ResourcePolicy::Discardable discardable = ResourcePolicy::OWNED_RETAIN, Dali::Integration::PixelBuffer* pixBuf = nullptr );
/**
* Initializes internal class members
/**
* Get interface to features that are active only if the Bitmap was created
* with a BITMAP_2D_PACKED_PIXELS profile. */
- virtual const PackedPixelsProfile* GetPackedPixelsProfile() const { return 0; }
+ virtual const PackedPixelsProfile* GetPackedPixelsProfile() const { return nullptr; }
/**
* Get interface to features that are active only if the Bitmap was created
* with a BITMAP_2D_PACKED_PIXELS profile. */
- virtual PackedPixelsProfile* GetPackedPixelsProfile() { return 0; }
+ virtual PackedPixelsProfile* GetPackedPixelsProfile() { return nullptr; }
/**@}*/ ///< End of packed pixel features.
virtual ~CompressedProfile() {}
};
- virtual const CompressedProfile* GetCompressedProfile() const { return 0; }
- virtual CompressedProfile* GetCompressedProfile() { return 0; }
+ virtual const CompressedProfile* GetCompressedProfile() const { return nullptr; }
+ virtual CompressedProfile* GetCompressedProfile() { return nullptr; }
/**@}*/
}
Core::Core()
-: mImpl( NULL )
+: mImpl( nullptr )
{
}
std::string ArgListToString(const char *format, va_list args)
{
std::string str; // empty string
- if(format != NULL)
+ if(format != nullptr)
{
- char* buffer = NULL;
+ char* buffer = nullptr;
int err = vasprintf(&buffer, format, args);
if(err >= 0) // No error
{
BlendingOptions::BlendingOptions()
: mBitmask( 0u ),
- mBlendColor( NULL )
+ mBlendColor( nullptr )
{
SetBlendFunc( BlendFactor::SRC_ALPHA, BlendFactor::ONE_MINUS_SRC_ALPHA,
BlendFactor::ONE, BlendFactor::ONE_MINUS_SRC_ALPHA );
{
if( Color::TRANSPARENT == color )
{
- mBlendColor = NULL;
+ mBlendColor = nullptr;
}
else
{
* @param size The size of the memory block to allocate in bytes. Must be non-zero.
*/
Block( SizeType size )
- : nextBlock( NULL )
+ : nextBlock( nullptr )
#ifdef DEBUG_ENABLED
,mBlockSize( size )
#endif
mCurrentBlock( &mMemoryBlocks ),
mCurrentBlockCapacity( initialCapacity ),
mCurrentBlockSize( 0 ),
- mDeletedObjects( NULL )
+ mDeletedObjects( nullptr )
{
// We need enough room to store the deleted list in the data
DALI_ASSERT_DEBUG( mFixedSize >= sizeof( void* ) );
* @brief Constructor
*/
MemoryPoolObjectAllocator()
- : mPool( NULL )
+ : mPool( nullptr )
{
ResetMemoryPool();
}
MessageBuffer::MessageBuffer( std::size_t initialCapacity )
: mInitialCapacity( initialCapacity / WORD_SIZE ),
- mData( NULL ),
- mNextSlot( NULL ),
+ mData( nullptr ),
+ mNextSlot( nullptr ),
mCapacity( 0 ),
mSize( 0 )
{
return Iterator( mData );
}
- return Iterator( NULL );
+ return Iterator( nullptr );
}
void MessageBuffer::Reset()
{
mData = reinterpret_cast<WordType*>( malloc( newCapacity * WORD_SIZE ) );
}
- DALI_ASSERT_ALWAYS( NULL != mData );
+ DALI_ASSERT_ALWAYS( nullptr != mData );
mCapacity = newCapacity;
mNextSlot = mData + mSize;
: mCurrent(current),
mMessageSize(0)
{
- if( NULL != mCurrent )
+ if( nullptr != mCurrent )
{
// The first word is the size of the following object
mMessageSize = *mCurrent++;
// Inlined for performance
WordType* Get()
{
- return ( 0 != mMessageSize ) ? mCurrent : NULL;
+ return ( 0 != mMessageSize ) ? mCurrent : nullptr;
}
// Inlined for performance
}
// Find the immediate Layer parent
- for( Actor* parent = mParent; !layer && parent != NULL; parent = parent->GetParent() )
+ for( Actor* parent = mParent; !layer && parent != nullptr; parent = parent->GetParent() )
{
if( parent->IsLayer() )
{
mChildren->erase( iter );
DALI_ASSERT_DEBUG( actor->GetParent() == this );
- actor->SetParent( NULL );
+ actor->SetParent( nullptr );
break;
}
uint32_t Actor::GetChildCount() const
{
- return ( NULL != mChildren ) ? static_cast<uint32_t>( mChildren->size() ) : 0; // only 4,294,967,295 children per actor
+ return ( nullptr != mChildren ) ? static_cast<uint32_t>( mChildren->size() ) : 0; // only 4,294,967,295 children per actor
}
ActorPtr Actor::GetChildAt( uint32_t index ) const
ActorPtr Actor::FindChildByName( const std::string& actorName )
{
- ActorPtr child = 0;
+ ActorPtr child = nullptr;
if( actorName == mName )
{
child = this;
ActorPtr Actor::FindChildById( const uint32_t id )
{
- ActorPtr child = 0;
+ ActorPtr child = nullptr;
if( id == GetId() )
{
child = this;
{
// Likely scenario is that once gesture-data is created for this actor, the actor will require
// that gesture for its entire life-time so no need to destroy it until the actor is destroyed
- if( NULL == mGestureData )
+ if( nullptr == mGestureData )
{
mGestureData = new ActorGestureData;
}
Actor::Actor( DerivedType derivedType, const SceneGraph::Node& node )
: Object( &node ),
mScene( nullptr ),
- mParent( NULL ),
- mChildren( NULL ),
- mRenderers( NULL ),
- mParentOrigin( NULL ),
- mAnchorPoint( NULL ),
- mRelayoutData( NULL ),
- mGestureData( NULL ),
+ mParent( nullptr ),
+ mChildren( nullptr ),
+ mRenderers( nullptr ),
+ mParentOrigin( nullptr ),
+ mAnchorPoint( nullptr ),
+ mRelayoutData( nullptr ),
+ mGestureData( nullptr ),
mTouchedSignal(),
mHoveredSignal(),
mWheelEventSignal(),
ActorConstIter endIter = mChildren->end();
for( ActorIter iter = mChildren->begin(); iter != endIter; ++iter )
{
- (*iter)->SetParent( NULL );
+ (*iter)->SetParent( nullptr );
}
}
delete mChildren;
const PropertyBase* Actor::GetSceneObjectAnimatableProperty( Property::Index index ) const
{
- const PropertyBase* property( NULL );
+ const PropertyBase* property( nullptr );
switch( index )
{
const PropertyInputImpl* Actor::GetSceneObjectInputProperty( Property::Index index ) const
{
- const PropertyInputImpl* property( NULL );
+ const PropertyInputImpl* property( nullptr );
switch( index )
{
}
else // parent being set to NULL
{
- DALI_ASSERT_ALWAYS( mParent != NULL && "Actor should have a parent" );
+ DALI_ASSERT_ALWAYS( mParent != nullptr && "Actor should have a parent" );
- mParent = NULL;
+ mParent = nullptr;
if ( EventThreadServices::IsCoreRunning() && // Don't emit signals or send messages during Core destruction
OnScene() )
CameraActor::CameraActor( const SceneGraph::Node& node )
: Actor( Actor::BASIC, node ),
- mSceneObject( NULL ),
+ mSceneObject( nullptr ),
mTarget( SceneGraph::Camera::DEFAULT_TARGET_POSITION ),
mType( SceneGraph::Camera::DEFAULT_TYPE ),
mProjectionMode( SceneGraph::Camera::DEFAULT_MODE ),
const PropertyInputImpl* CameraActor::GetSceneObjectInputProperty( Property::Index index ) const
{
- const PropertyInputImpl* property( NULL );
+ const PropertyInputImpl* property( nullptr );
switch( index )
{
Layer::Layer( Actor::DerivedType type, const SceneGraph::Layer& layer )
: Actor( type, layer ),
- mLayerList( NULL ),
+ mLayerList( nullptr ),
mClippingBox( 0, 0, 0, 0 ),
mSortFunction( Layer::ZValue ),
mBehavior( Dali::Layer::LAYER_UI ),
DALI_ASSERT_DEBUG( NULL == mLayerList );
// Find the ordered layer-list
- for ( Actor* parent = mParent; parent != NULL; parent = parent->GetParent() )
+ for ( Actor* parent = mParent; parent != nullptr; parent = parent->GetParent() )
{
if( parent->IsLayer() )
{
mLayerList->UnregisterLayer(*this);
// mLayerList is only valid when on-stage
- mLayerList = NULL;
+ mLayerList = nullptr;
}
const SceneGraph::Layer& Layer::GetSceneGraphLayer() const
LayerList::LayerList( SceneGraph::UpdateManager& updateManager )
: mUpdateManager( updateManager ),
- mRoot( NULL )
+ mRoot( nullptr )
{
}
}
Animation::Animation( EventThreadServices& eventThreadServices, AnimationPlaylist& playlist, float durationSeconds, EndAction endAction, EndAction disconnectAction, AlphaFunction defaultAlpha )
-: mAnimation( NULL ),
+: mAnimation( nullptr ),
mEventThreadServices( eventThreadServices ),
mPlaylist( playlist ),
mFinishedSignal(),
void Animation::DestroySceneObject()
{
- if ( mAnimation != NULL )
+ if ( mAnimation != nullptr )
{
// Remove animation using a message to the update manager
RemoveAnimationMessage( mEventThreadServices.GetUpdateManager(), *mAnimation );
- mAnimation = NULL;
+ mAnimation = nullptr;
}
}
ConstraintBase::ConstraintBase( Object& object, Property::Index targetPropertyIndex, SourceContainer& sources )
: mEventThreadServices( EventThreadServices::Get() ),
mTargetObject( &object ),
- mSceneGraphConstraint( NULL ),
+ mSceneGraphConstraint( nullptr ),
mSources( sources ),
mObservedObjects(),
mTargetPropertyIndex( targetPropertyIndex ),
// Observe the object providing this property
if ( OBJECT_PROPERTY == source.sourceType )
{
- if ( source.object != NULL )
+ if ( source.object != nullptr )
{
ObserveObject( *source.object );
}
// Remove from scene-graph
RemoveConstraintMessage( GetEventThreadServices(), propertyOwner, *(mSceneGraphConstraint) );
// mSceneGraphConstraint will be deleted in update-thread, remove dangling pointer
- mSceneGraphConstraint = NULL;
+ mSceneGraphConstraint = nullptr;
}
}
}
void ConstraintBase::SceneObjectAdded( Object& object )
{
if ( mApplied &&
- ( NULL == mSceneGraphConstraint ) &&
+ ( nullptr == mSceneGraphConstraint ) &&
mTargetObject )
{
ConnectConstraint();
}
// mSceneGraphConstraint will be deleted in update-thread, remove dangling pointer
- mSceneGraphConstraint = NULL;
+ mSceneGraphConstraint = nullptr;
}
}
mSources.clear();
// Discard all object & scene-graph pointers
- mSceneGraphConstraint = NULL;
- mTargetObject = NULL;
+ mSceneGraphConstraint = nullptr;
+ mTargetObject = nullptr;
}
void ConstraintBase::ObserveObject( Object& object )
Source()
: sourceType( OBJECT_PROPERTY ),
propertyIndex( Property::INVALID_INDEX ),
- object( NULL )
+ object( nullptr )
{
}
Source( Dali::ConstraintSource& source )
: sourceType( source.sourceType ),
propertyIndex( source.propertyIndex ),
- object( NULL )
+ object( nullptr )
{
if ( source.object )
{
KeyFrames::KeyFrames()
: mType(Property::NONE),
- mKeyFrames(NULL)
+ mKeyFrames(nullptr)
{
}
const char* const SIGNAL_OBJECT_CREATED = "objectCreated";
const char* const SIGNAL_OBJECT_DESTROYED = "objectDestroyed";
-TypeRegistration mType( typeid( Dali::ObjectRegistry ), typeid( Dali::BaseHandle ), NULL );
+TypeRegistration mType( typeid( Dali::ObjectRegistry ), typeid( Dali::BaseHandle ), nullptr );
SignalConnectorType signalConnector1( mType, SIGNAL_OBJECT_CREATED, &ObjectRegistry::DoConnectSignal );
SignalConnectorType signalConnector2( mType, SIGNAL_OBJECT_DESTROYED, &ObjectRegistry::DoConnectSignal );
bool XyPlaneIntersect( const Vector4& pointA, const Vector4& pointB, Vector4& intersect )
{
- const Vector4* near = NULL;
- const Vector4* far = NULL;
+ const Vector4* near = nullptr;
+ const Vector4* far = nullptr;
if ( pointA.z > 0.0f && pointB.z < 0.0f )
{
*/
bool IsAnimatable( void ) const
{
- return NULL != mSceneGraphProperty;
+ return nullptr != mSceneGraphProperty;
}
/**
CustomPropertyMetadata( const std::string& propertyName,
const Property::Value& propertyValue,
Property::AccessMode accessMode )
- : PropertyMetadata( propertyValue, NULL, ( accessMode != Property::READ_ONLY ) ),
+ : PropertyMetadata( propertyValue, nullptr, ( accessMode != Property::READ_ONLY ) ),
name( propertyName ),
key( Property::INVALID_KEY ),
childPropertyIndex( Property::INVALID_INDEX )
int componentIndex,
const Dali::PropertyCondition& condition )
: mUpdateManager( updateManager ),
- mPropertyNotification( NULL ),
+ mPropertyNotification( nullptr ),
mPropertyNotificationManager( propertyNotificationManager ),
mObjectPropertyIndex( target.propertyIndex ),
mPropertyType( Property::NONE ),
void PropertyNotification::DestroySceneObject()
{
- if ( mPropertyNotification != NULL )
+ if ( mPropertyNotification != nullptr )
{
// Remove PropertyNotification using a message to the update manager
RemovePropertyNotificationMessage( mUpdateManager, *mPropertyNotification );
- mPropertyNotification = NULL;
+ mPropertyNotification = nullptr;
}
}
const char* const SIGNAL_CONTEXT_REGAINED = "contextRegained";
const char* const SIGNAL_SCENE_CREATED = "sceneCreated";
-TypeRegistration mType( typeid(Dali::Stage), typeid(Dali::BaseHandle), NULL );
+TypeRegistration mType( typeid(Dali::Stage), typeid(Dali::BaseHandle), nullptr );
SignalConnectorType signalConnector1( mType, SIGNAL_KEY_EVENT, &Stage::DoConnectSignal );
SignalConnectorType signalConnector2( mType, SIGNAL_EVENT_PROCESSING_FINISHED, &Stage::DoConnectSignal );
StagePtr Stage::GetCurrent()
{
- StagePtr stage( NULL );
+ StagePtr stage( nullptr );
// no checking in this version
ThreadLocalStorage* tls = ThreadLocalStorage::GetInternal();
if( tls )
void TypeInfo::AddActionFunction( const std::string &actionName, Dali::TypeInfo::ActionFunction function )
{
- if( NULL == function)
+ if( nullptr == function)
{
DALI_LOG_WARNING("Action function is empty\n");
}
void TypeInfo::AddConnectorFunction( const std::string& signalName, Dali::TypeInfo::SignalConnectorFunction function )
{
- if( NULL == function)
+ if( nullptr == function)
{
DALI_LOG_WARNING("Connector function is empty\n");
}
{
// The setter can be empty as a property can be read-only.
- if ( NULL == getFunc )
+ if ( nullptr == getFunc )
{
DALI_ASSERT_ALWAYS( ! "GetProperty Function is empty" );
}
// The setter can be empty as a property can be read-only.
- if ( NULL == getFunc )
+ if ( nullptr == getFunc )
{
DALI_ASSERT_ALWAYS( ! "GetProperty Function is empty" );
}
}
// If memory cache failed check the file system for a binary or return a source-only ShaderData:
- if( shaderData.Get() == NULL )
+ if( shaderData.Get() == nullptr )
{
// Allocate the structure that returns the loaded shader:
shaderData = new ShaderData( vertexSource, fragmentSource, hints );
const GestureType::Value type( detector.GetType() );
GestureDetectorContainer*& containerPtr( GetContainerPtr( type ) );
- if ( NULL == containerPtr )
+ if ( nullptr == containerPtr )
{
containerPtr = new GestureDetectorContainer;
}
{
gesturesRequired = GestureType::Value( gesturesRequired & ~type );
delete containerPtr;
- containerPtr = NULL;
+ containerPtr = nullptr;
}
}
}
DALI_ASSERT_DEBUG( ! "Invalid Type" );
- static GestureDetectorContainer* invalidType( NULL );
+ static GestureDetectorContainer* invalidType( nullptr );
return invalidType;
}
struct HitActor
{
HitActor()
- : actor( NULL ),
+ : actor( nullptr ),
distance( std::numeric_limits<float>::max() ),
depth( std::numeric_limits<int>::min() )
{
AllocAndEmitHoverSignals( event.time, hoverStartConsumedActorHandle, currentPoint );
}
- mLastPrimaryHitActor.SetActor( NULL );
- mLastConsumedActor.SetActor( NULL );
- mHoverStartConsumedActor.SetActor( NULL );
+ mLastPrimaryHitActor.SetActor( nullptr );
+ mLastConsumedActor.SetActor( nullptr );
+ mHoverStartConsumedActor.SetActor( nullptr );
mLastRenderTask.Reset();
return; // No need for hit testing
if ( primaryPointState == PointState::FINISHED )
{
- mLastPrimaryHitActor.SetActor( NULL );
- mLastConsumedActor.SetActor( NULL );
+ mLastPrimaryHitActor.SetActor( nullptr );
+ mLastConsumedActor.SetActor( nullptr );
mLastRenderTask.Reset();
}
else
}
else
{
- mLastConsumedActor.SetActor( NULL );
+ mLastConsumedActor.SetActor( nullptr );
}
mLastRenderTask = currentRenderTask;
}
else
{
- mLastPrimaryHitActor.SetActor( NULL );
- mLastConsumedActor.SetActor( NULL );
+ mLastPrimaryHitActor.SetActor( nullptr );
+ mLastConsumedActor.SetActor( nullptr );
mLastRenderTask.Reset();
}
}
primaryPoint.SetState( primaryPointState );
}
- mHoverStartConsumedActor.SetActor( NULL );
+ mHoverStartConsumedActor.SetActor( nullptr );
}
// No break, Fallthrough
mCurrentRenderTask(),
mMinTouchesRequired( 1 ),
mMaxTouchesRequired( 1 ),
- mCurrentLongPressEvent( NULL ),
+ mCurrentLongPressEvent( nullptr ),
mMinimumHoldingTime( DEFAULT_MINIMUM_HOLDING_TIME )
{
}
// Set mCurrentLongPressEvent to use inside overridden methods called from ProcessAndEmit()
mCurrentLongPressEvent = &longPressEvent;
ProcessAndEmit( hitTestResults );
- mCurrentLongPressEvent = NULL;
+ mCurrentLongPressEvent = nullptr;
}
else
{
: GestureProcessor( GestureType::PINCH ),
mPinchGestureDetectors(),
mCurrentPinchEmitters(),
- mCurrentPinchEvent(NULL),
+ mCurrentPinchEvent(nullptr),
mMinimumPinchDistance(-1.0f),
mMinimumTouchEvents( MINIMUM_TOUCH_EVENTS_REQUIRED ),
mMinimumTouchEventsAfterStart( MINIMUM_TOUCH_EVENTS_REQUIRED_AFTER_START )
// Set mCurrentPinchEvent to use inside overridden methods called from ProcessAndEmit()
mCurrentPinchEvent = &pinchEvent;
ProcessAndEmit( hitTestResults );
- mCurrentPinchEvent = NULL;
+ mCurrentPinchEvent = nullptr;
}
break;
}
// Set mCurrentRotationEvent to use inside overridden methods called from ProcessAndEmit()
mCurrentRotationEvent = &rotationEvent;
ProcessAndEmit( hitTestResults );
- mCurrentRotationEvent = NULL;
+ mCurrentRotationEvent = nullptr;
}
break;
}
mMaxTapsRequired( 1 ),
mMinTouchesRequired( 1 ),
mMaxTouchesRequired( 1 ),
- mCurrentTapEvent( NULL ),
+ mCurrentTapEvent( nullptr ),
mPossibleProcessed( false )
{
}
mCurrentTapEvent = &tapEvent;
ProcessAndEmit( hitTestResults );
}
- mCurrentTapEvent = NULL;
+ mCurrentTapEvent = nullptr;
mPossibleProcessed = false;
}
break;
}
else
{
- mLastConsumedActor.SetActor( NULL );
+ mLastConsumedActor.SetActor( nullptr );
}
mLastRenderTask = currentRenderTask;
AllocAndEmitTouchSignals( event.time, touchDownConsumedActorHandle, currentPoint );
}
- mTouchDownConsumedActor.SetActor( NULL );
+ mTouchDownConsumedActor.SetActor( nullptr );
DALI_FALLTHROUGH;
}
// Do not set mLastPrimaryHitActor to NULL we may be iterating through its observers
- mLastConsumedActor.SetActor( NULL );
+ mLastConsumedActor.SetActor( nullptr );
mLastRenderTask.Reset();
}
}
if(HasAlphaChannel())
{
uint8_t* pixelBuffer=GetBuffer();
- if(pixelBuffer != NULL)
+ if(pixelBuffer != nullptr)
{
uint8_t* row = pixelBuffer;
* Constructor
* @param[in] discardable Flag to tell the bitmap if it can delete the buffer with the pixel data.
*/
- BitmapPackedPixel( ResourcePolicy::Discardable discardable = ResourcePolicy::OWNED_RETAIN, Dali::Integration::PixelBuffer* pixBuf = 0 );
+ BitmapPackedPixel( ResourcePolicy::Discardable discardable = ResourcePolicy::OWNED_RETAIN, Dali::Integration::PixelBuffer* pixBuf = nullptr );
public:
virtual const Bitmap::PackedPixelsProfile* GetPackedPixelsProfile() const { return this; }
DevelPixelData::PixelDataBuffer PixelData::ReleaseBuffer()
{
DevelPixelData::PixelDataBuffer pixelDataBuffer(mBuffer, mBufferSize, mReleaseFunction);
- mBuffer = NULL;
+ mBuffer = nullptr;
return pixelDataBuffer;
}
const char* const SIGNAL_FINISHED = "finished";
-TypeRegistration mType( typeid( Dali::RenderTask ), typeid( Dali::BaseHandle ), NULL, RenderTaskDefaultProperties );
+TypeRegistration mType( typeid( Dali::RenderTask ), typeid( Dali::BaseHandle ), nullptr, RenderTaskDefaultProperties );
SignalConnectorType signalConnector1( mType, SIGNAL_FINISHED, &RenderTask::DoConnectSignal );
void RenderTask::SetFrameBuffer( FrameBufferPtr frameBuffer )
{
mFrameBuffer = frameBuffer;
- Render::FrameBuffer* renderFrameBufferPtr( NULL );
+ Render::FrameBuffer* renderFrameBufferPtr( nullptr );
if( frameBuffer )
{
renderFrameBufferPtr = mFrameBuffer->GetRenderObject();
const SceneGraph::PropertyBase* RenderTask::GetSceneObjectAnimatableProperty( Property::Index index ) const
{
- const SceneGraph::PropertyBase* property( NULL );
+ const SceneGraph::PropertyBase* property( nullptr );
switch ( index )
{
FrameBuffer::FrameBuffer( uint32_t width, uint32_t height, Mask attachments )
: mEventThreadServices( EventThreadServices::Get() ),
- mRenderObject( NULL ),
+ mRenderObject( nullptr ),
mColor{ nullptr },
mDepth( nullptr ),
mStencil( nullptr ),
Geometry::Geometry()
: mEventThreadServices( EventThreadServices::Get() ),
- mRenderObject( NULL ),
+ mRenderObject( nullptr ),
mType(Dali::Geometry::TRIANGLES)
{
}
const SceneGraph::PropertyBase* Renderer::GetSceneObjectAnimatableProperty( Property::Index index ) const
{
- const SceneGraph::PropertyBase* property = NULL;
+ const SceneGraph::PropertyBase* property = nullptr;
if( index == DevelRenderer::Property::OPACITY )
{
void Sampler::SetFilterMode( Dali::FilterMode::Type minFilter, Dali::FilterMode::Type magFilter )
{
- if( NULL != mRenderObject )
+ if( nullptr != mRenderObject )
{
SetFilterModeMessage( mEventThreadServices.GetUpdateManager(), *mRenderObject, static_cast< unsigned int >( minFilter ), static_cast< unsigned int >( magFilter ) );
}
void Sampler::SetWrapMode( Dali::WrapMode::Type rWrap, Dali::WrapMode::Type sWrap, Dali::WrapMode::Type tWrap )
{
- if( NULL != mRenderObject )
+ if( nullptr != mRenderObject )
{
SetWrapModeMessage( mEventThreadServices.GetUpdateManager(), *mRenderObject, static_cast< unsigned int >( rWrap ), static_cast< unsigned int >( sWrap ), static_cast< unsigned int >( tWrap ) );
}
Sampler::Sampler()
:mEventThreadServices( EventThreadServices::Get() ),
- mRenderObject( NULL )
+ mRenderObject( nullptr )
{
}
Texture::Texture(TextureType::Type type, Pixel::Format format, ImageDimensions size )
: mEventThreadServices( EventThreadServices::Get() ),
- mRenderObject( NULL ),
+ mRenderObject( nullptr ),
mNativeImage(),
mSize( size ),
mType( type ),
Texture::Texture( NativeImageInterfacePtr nativeImageInterface )
: mEventThreadServices( EventThreadServices::Get() ),
- mRenderObject( NULL ),
+ mRenderObject( nullptr ),
mNativeImage( nativeImageInterface ),
mSize( nativeImageInterface->GetWidth(), nativeImageInterface->GetHeight() ),
mType( TextureType::TEXTURE_2D ),
else
{
unsigned int pixelDataSize = pixelData->GetWidth()*pixelData->GetHeight();
- if( pixelData->GetBuffer() == NULL || pixelDataSize == 0 )
+ if( pixelData->GetBuffer() == nullptr || pixelDataSize == 0 )
{
DALI_LOG_ERROR( "PixelData is empty\n");
}
for( uint32_t i(textureCount); i<=index; ++i )
{
- mTextures[i] = NULL;
+ mTextures[i] = nullptr;
if( !samplerExist )
{
- mSamplers[i] = NULL;
+ mSamplers[i] = nullptr;
}
}
}
mTextures[index]= texture;
- Render::Texture* renderTexture(0);
+ Render::Texture* renderTexture(nullptr);
if( texture )
{
renderTexture = texture->GetRenderObject();
Texture* TextureSet::GetTexture( uint32_t index ) const
{
- Texture* result(0);
+ Texture* result(nullptr);
if( index < mTextures.size() )
{
result = mTextures[index].Get();
mSamplers.resize( index + 1 );
for( uint32_t i = samplerCount; i<=index; ++i )
{
- mSamplers[i] = NULL;
+ mSamplers[i] = nullptr;
}
}
mSamplers[index] = sampler;
- Render::Sampler* renderSampler(0);
+ Render::Sampler* renderSampler(nullptr);
if( sampler )
{
renderSampler = sampler->GetSamplerRenderObject();
Sampler* TextureSet::GetSampler( uint32_t index ) const
{
- Sampler* result(0);
+ Sampler* result(nullptr);
if( index < mSamplers.size() )
{
result = mSamplers[index].Get();
TextureSet::TextureSet()
:mEventThreadServices( EventThreadServices::Get() ),
- mSceneObject( NULL )
+ mSceneObject( nullptr )
{
}
VertexBuffer::VertexBuffer()
: mEventThreadServices( EventThreadServices::Get() ),
- mRenderObject( NULL ),
+ mRenderObject( nullptr ),
mBufferFormatSize( 0 ),
mSize( 0 )
{
{
RenderInstruction::RenderInstruction()
-: mRenderTracker( NULL ),
+: mRenderTracker( nullptr ),
mClearColor(),
mIsViewportSet( false ),
mIsClearColorSet( false ),
mIgnoreRenderToFbo( false ),
- mFrameBuffer( 0 ),
- mCamera( 0 ),
+ mFrameBuffer( nullptr ),
+ mCamera( nullptr ),
mNextFreeRenderList( 0 )
{
// reserve 6 lists, which is enough for three layers with opaque and transparent things on
// Return null if the caller has passed an invalid index:
if( index >= std::min( mNextFreeRenderList, mRenderLists.Size() ) )
{
- return 0;
+ return nullptr;
}
return mRenderLists[ index ];
{
mCamera = camera;
mViewport = viewport ? *viewport : Viewport();
- mIsViewportSet = NULL != viewport;
+ mIsViewportSet = nullptr != viewport;
mClearColor = clearColor ? *clearColor : Color::BLACK;
- mIsClearColorSet = NULL != clearColor;
- mRenderTracker = NULL;
+ mIsClearColorSet = nullptr != clearColor;
+ mRenderTracker = nullptr;
mNextFreeRenderList = 0;
mFrameBuffer = frameBuffer;
mModelViewMatrix( false ),
mColor( Vector4::ZERO ),
mSize(),
- mRenderer( NULL ),
- mNode( NULL ),
- mTextureSet( NULL ),
+ mRenderer( nullptr ),
+ mNode( nullptr ),
+ mTextureSet( nullptr ),
mDepthIndex( 0 ),
mIsOpaque( true ),
mIsUpdated( false )
*/
RenderList()
: mNextFree( 0 ),
- mClippingBox( NULL ),
- mSourceLayer( NULL ),
+ mClippingBox( nullptr ),
+ mSourceLayer( nullptr ),
mHasColorRenderItems( false )
{
}
mNextFree = 0;
delete mClippingBox;
- mClippingBox = NULL;
+ mClippingBox = nullptr;
}
/**
*/
bool IsClipping() const
{
- return ( NULL != mClippingBox );
+ return ( nullptr != mClippingBox );
}
/**
}
RenderManager::RenderManager()
-: mImpl(NULL)
+: mImpl(nullptr)
{
}
clearMask |= GL_STENCIL_BUFFER_BIT;
}
- if( !instruction.mIgnoreRenderToFbo && ( instruction.mFrameBuffer != 0 ) )
+ if( !instruction.mIgnoreRenderToFbo && ( instruction.mFrameBuffer != nullptr ) )
{
// Offscreen buffer rendering
if ( instruction.mIsViewportSet )
}
bool clearFullFrameRect = true;
- if( instruction.mFrameBuffer != 0 )
+ if( instruction.mFrameBuffer != nullptr )
{
Viewport frameRect( 0, 0, instruction.mFrameBuffer->GetWidth(), instruction.mFrameBuffer->GetHeight() );
clearFullFrameRect = ( frameRect == viewportRect );
{
RenderTracker::RenderTracker()
-: mGlSyncAbstraction( NULL ),
- mSyncObject( NULL ),
+: mGlSyncAbstraction( nullptr ),
+ mSyncObject( nullptr ),
mSyncTrigger( 0 )
{
TRACKER_LOG(Debug::Verbose);
if( mSyncObject )
{
mGlSyncAbstraction->DestroySyncObject( mSyncObject );
- mSyncObject = NULL;
+ mSyncObject = nullptr;
}
}
if( mSyncObject )
{
mGlSyncAbstraction->DestroySyncObject( mSyncObject );
- mSyncObject = NULL;
+ mSyncObject = nullptr;
}
ResetSyncFlag();
mSyncObject = mGlSyncAbstraction->CreateSyncObject();
{
SetSyncFlag();
mGlSyncAbstraction->DestroySyncObject( mSyncObject );
- mSyncObject = NULL;
+ mSyncObject = nullptr;
TRACKER_LOG_FMT(Debug::General, " Synced\n");
return;
{
RenderDataProvider::RenderDataProvider( AnimatableProperty< float >& opacity )
-: mUniformMapDataProvider( NULL ),
- mShader( NULL ),
+: mUniformMapDataProvider( nullptr ),
+ mShader( nullptr ),
mOpacity( opacity )
{
}
return &state;
}
}
- return NULL;
+ return nullptr;
}
void FrameBufferStateCache::DeleteFrameBuffer( GLuint frameBufferId )
{
RenderQueue::RenderQueue()
-: container0( NULL ),
- container1( NULL )
+: container0( nullptr ),
+ container1( nullptr )
{
container0 = new MessageBuffer( INITIAL_BUFFER_SIZE );
container1 = new MessageBuffer( INITIAL_BUFFER_SIZE );
MessageBuffer* RenderQueue::GetCurrentContainer( BufferIndex bufferIndex )
{
- MessageBuffer* container( NULL );
+ MessageBuffer* container( nullptr );
/**
* The update-thread queues messages with one container,
if( MAX_BUFFER_SIZE < container0->GetCapacity() )
{
delete container0;
- container0 = NULL;
+ container0 = nullptr;
container0 = new MessageBuffer( INITIAL_BUFFER_SIZE );
}
}
if( MAX_BUFFER_SIZE < container1->GetCapacity() )
{
delete container1;
- container1 = NULL;
+ container1 = nullptr;
container1 = new MessageBuffer( INITIAL_BUFFER_SIZE );
}
}
Geometry::Geometry()
: mIndices(),
- mIndexBuffer(NULL),
+ mIndexBuffer(nullptr),
mGeometryType( Dali::Geometry::TRIANGLES ),
mIndicesChanged(false),
mHasBeenUpdated(false),
{
if( mIndices.Empty() )
{
- mIndexBuffer = NULL;
+ mIndexBuffer = nullptr;
}
else
{
- if ( mIndexBuffer == NULL )
+ if ( mIndexBuffer == nullptr )
{
mIndexBuffer = new GpuBuffer( context );
}
DepthFunction::Type depthFunction,
StencilParameters& stencilParameters )
: mRenderDataProvider( dataProvider ),
- mContext( NULL),
+ mContext( nullptr),
mGeometry( geometry ),
mUniformIndexMap(),
mAttributesLocation(),
{
if( !mIsCompressed )
{
- context.TexImage2D(GL_TEXTURE_2D, 0, mGlInternalFormat, mWidth, mHeight, 0, mGlFormat, mPixelDataType, 0 );
+ context.TexImage2D(GL_TEXTURE_2D, 0, mGlInternalFormat, mWidth, mHeight, 0, mGlFormat, mPixelDataType, nullptr );
}
else
{
- context.CompressedTexImage2D(GL_TEXTURE_2D, 0, mGlInternalFormat, mWidth, mHeight, 0, 0, 0 );
+ context.CompressedTexImage2D(GL_TEXTURE_2D, 0, mGlInternalFormat, mWidth, mHeight, 0, 0, nullptr );
}
}
else if( mType == TextureType::TEXTURE_CUBE )
{
for( uint32_t i(0); i<6; ++i )
{
- context.TexImage2D(GL_TEXTURE_CUBE_MAP_POSITIVE_X + i, 0, mGlInternalFormat, mWidth, mHeight, 0, mGlFormat, mPixelDataType, 0 );
+ context.TexImage2D(GL_TEXTURE_CUBE_MAP_POSITIVE_X + i, 0, mGlInternalFormat, mWidth, mHeight, 0, mGlFormat, mPixelDataType, nullptr );
}
}
else
{
for( uint32_t i(0); i<6; ++i )
{
- context.CompressedTexImage2D(GL_TEXTURE_CUBE_MAP_POSITIVE_X + i, 0, mGlInternalFormat, mWidth, mHeight, 0, 0, 0 );
+ context.CompressedTexImage2D(GL_TEXTURE_CUBE_MAP_POSITIVE_X + i, 0, mGlInternalFormat, mWidth, mHeight, 0, 0, nullptr );
}
}
context.TexParameteri( mTarget, GL_TEXTURE_WRAP_R, GL_WRAP_DEFAULT );
void Texture::Upload( Context& context, PixelDataPtr pixelData, const Internal::Texture::UploadParams& params )
{
- DALI_ASSERT_ALWAYS( mNativeImage == NULL );
+ DALI_ASSERT_ALWAYS( mNativeImage == nullptr );
//Get pointer to the data of the PixelData object
uint8_t* buffer( pixelData->GetBuffer() );
{
VertexBuffer::VertexBuffer()
-:mFormat(NULL),
- mData(NULL),
- mGpuBuffer(NULL),
+:mFormat(nullptr),
+ mData(nullptr),
+ mGpuBuffer(nullptr),
mSize(0),
mDataChanged(true)
{
{
ProgramController::ProgramController( Integration::GlAbstraction& glAbstraction )
-: mShaderSaver( 0 ),
+: mShaderSaver( nullptr ),
mGlAbstraction( glAbstraction ),
- mCurrentProgram( NULL ),
+ mCurrentProgram( nullptr ),
mProgramBinaryFormat( 0 ),
mNumberOfProgramBinaryFormats( 0 )
{
for ( ProgramIterator iter = mProgramCache.Begin(); iter != end; ++iter )
{
Program* program = (*iter)->GetProgram();
- program->SetProjectionMatrix( NULL );
- program->SetViewMatrix( NULL );
+ program->SetProjectionMatrix( nullptr );
+ program->SetViewMatrix( nullptr );
}
}
mNumberOfProgramBinaryFormats = 0;
mProgramBinaryFormat = 0;
- SetCurrentProgram( NULL );
+ SetCurrentProgram( nullptr );
// Inform programs they are no longer valid
const ProgramIterator end = mProgramCache.End();
for ( ProgramIterator iter = mProgramCache.Begin(); iter != end; ++iter )
Program* ProgramController::GetProgram( size_t shaderHash )
{
- Program* program = NULL;
+ Program* program = nullptr;
const ProgramIterator end = mProgramCache.End();
for ( ProgramIterator iter = mProgramCache.Begin(); iter != end; ++iter )
{
DALI_ASSERT_DEBUG( programData->GetBufferSize() > 0 );
DALI_ASSERT_DEBUG( mShaderSaver && "SetShaderSaver() should have been called during startup." );
- if( mShaderSaver != NULL )
+ if( mShaderSaver != nullptr )
{
mShaderSaver->SaveBinary( programData );
}
size_t shaderHash = shaderData->GetHashValue();
Program* program = cache.GetProgram( shaderHash );
- if( NULL == program )
+ if( nullptr == program )
{
// program not found so create it
program = new Program( cache, shaderData, modifiesGeometry );
{
char* outerToken = strtok_r( uniform + UNIFORM.mLength, ";", &uniform );
- char* nextPtr = NULL;
+ char* nextPtr = nullptr;
char* token = strtok_r( outerToken, DELIMITERS, &nextPtr );
while ( token )
{
if ( std::find(SAMPLER_TYPES, END_SAMPLER_TYPES, token) != END_SAMPLER_TYPES )
{
bool found( false );
- token = strtok_r( NULL, DELIMITERS, &nextPtr );
+ token = strtok_r( nullptr, DELIMITERS, &nextPtr );
for (uint32_t i=0; i < static_cast<uint32_t>( samplerUniformLocations.size() ); ++i)
{
if ( samplerUniformLocations[i].position == -1 &&
}
}
- token = strtok_r( NULL, DELIMITERS, &nextPtr );
+ token = strtok_r( nullptr, DELIMITERS, &nextPtr );
}
uniform = strstr( uniform, UNIFORM );
Program::Program( ProgramCache& cache, Internal::ShaderDataPtr shaderData, bool modifiesGeometry )
: mCache( cache ),
mGlAbstraction( mCache.GetGlAbstraction() ),
- mProjectionMatrix( NULL ),
- mViewMatrix( NULL ),
+ mProjectionMatrix( nullptr ),
+ mViewMatrix( nullptr ),
mLinked( false ),
mVertexShaderId( 0 ),
mFragmentShaderId( 0 ),
void Program::Load()
{
- DALI_ASSERT_ALWAYS( NULL != mProgramData.Get() && "Program data is not initialized" );
+ DALI_ASSERT_ALWAYS( nullptr != mProgramData.Get() && "Program data is not initialized" );
DALI_ASSERT_DEBUG( mProgramId == 0 && "mProgramId != 0, so about to leak a GL resource by overwriting it." );
LOG_GL( "CreateProgram()\n" );
// Allocate space for the bytecode in ShaderData
mProgramData->AllocateBuffer(binaryLength);
// Copy the bytecode to ShaderData
- CHECK_GL( mGlAbstraction, mGlAbstraction.GetProgramBinary(mProgramId, binaryLength, NULL, &binaryFormat, mProgramData->GetBufferData()) );
+ CHECK_GL( mGlAbstraction, mGlAbstraction.GetProgramBinary(mProgramId, binaryLength, nullptr, &binaryFormat, mProgramData->GetBufferData()) );
mCache.StoreBinary( mProgramData );
DALI_LOG_INFO( Debug::Filter::gShader, Debug::General, "Saved binary.\n" );
}
{
CHECK_GL( mGlAbstraction, mGlAbstraction.UseProgram(0) );
- mCache.SetCurrentProgram( NULL );
+ mCache.SetCurrentProgram( nullptr );
}
if (mProgramId)
}
LOG_GL( "ShaderSource(%d)\n", shaderId );
- CHECK_GL( mGlAbstraction, mGlAbstraction.ShaderSource(shaderId, 1, &src, NULL ) );
+ CHECK_GL( mGlAbstraction, mGlAbstraction.ShaderSource(shaderId, 1, &src, nullptr ) );
LOG_GL( "CompileShader(%d)\n", shaderId );
CHECK_GL( mGlAbstraction, mGlAbstraction.CompileShader( shaderId ) );
Shader::Shader( Dali::Shader::Hint::Value& hints )
: mHints( hints ),
- mProgram( NULL ),
+ mProgram( nullptr ),
mConnectionObservers()
{
AddUniformMapObserver( *this );
ConditionFunction LessThan::GetFunction(Property::Type valueType)
{
- ConditionFunction function = NULL;
+ ConditionFunction function = nullptr;
switch(valueType)
{
ConditionFunction GreaterThan::GetFunction(Property::Type valueType)
{
- ConditionFunction function = NULL;
+ ConditionFunction function = nullptr;
switch(valueType)
{
ConditionFunction Inside::GetFunction(Property::Type valueType)
{
- ConditionFunction function = NULL;
+ ConditionFunction function = nullptr;
switch(valueType)
{
ConditionFunction Outside::GetFunction(Property::Type valueType)
{
- ConditionFunction function = NULL;
+ ConditionFunction function = nullptr;
switch(valueType)
{
ConditionFunction Step::GetFunction(Property::Type valueType)
{
- ConditionFunction function = NULL;
+ ConditionFunction function = nullptr;
switch(valueType)
{
ConditionFunction Step::GetCompareFunction( Property::Type valueType )
{
- ConditionFunction function = NULL;
+ ConditionFunction function = nullptr;
if( valueType == Property::VECTOR3 )
{
function = EvalAndCompareVector3;
ConditionFunction VariableStep::GetFunction( Property::Type valueType )
{
- ConditionFunction function = NULL;
+ ConditionFunction function = nullptr;
switch( valueType )
{
: mObject(&object),
mPropertyIndex(propertyIndex),
mPropertyType(propertyType),
- mProperty(NULL),
+ mProperty(nullptr),
mComponentIndex(componentIndex),
mConditionType(condition),
mArguments(arguments),
mValid(false),
mNotifyMode( Dali::PropertyNotification::DISABLED ),
- mConditionFunction(NULL)
+ mConditionFunction(nullptr)
{
SetNotifyMode(notifyMode);
}
}
}
- return NULL;
+ return nullptr;
}
UniformMap::SizeType UniformMap::Count() const
}
UniformPropertyMapping()
- : propertyPtr( NULL ),
+ : propertyPtr( nullptr ),
uniformName( "" ),
uniformNameHash( 0 )
{
mInGesture( false ),
mPredictionAmountOverridden( false ),
mSmoothingAmountOverridden( false ),
- mProfiling( NULL ),
+ mProfiling( nullptr ),
// Set environment variable defaults:
mPredictionMode( DEFAULT_PREDICTION_MODE ),
Layer& layer = **iter;
const bool tryReuseRenderList( viewMatrixHasNotChanged && layer.CanReuseRenderers( &renderTask.GetCamera() ) );
const bool isLayer3D = layer.GetBehavior() == Dali::Layer::LAYER_3D;
- RenderList* renderList = NULL;
+ RenderList* renderList = nullptr;
if( layer.IsRoot() && ( layer.GetDirtyFlags() != NodePropertyFlags::NOTHING ) )
{
struct SortAttributes
{
SortAttributes()
- : renderItem( NULL ),
- shader( NULL ),
- textureSet( NULL ),
- geometry( NULL ),
+ : renderItem( nullptr ),
+ shader( nullptr ),
+ textureSet( nullptr ),
+ geometry( nullptr ),
zValue( 0.0f )
{
}
Layer* FindLayer( Node& node )
{
Node* currentNode( &node );
- Layer* layer( NULL );
+ Layer* layer( nullptr );
while( currentNode )
{
- if( ( layer = currentNode->GetLayer() ) != NULL )
+ if( ( layer = currentNode->GetLayer() ) != nullptr )
{
return layer;
}
currentNode = currentNode->GetParent();
}
- return NULL;
+ return nullptr;
}
/**
{
RenderTask& renderTask = **iter;
- const bool hasFrameBuffer = NULL != renderTask.GetFrameBuffer();
+ const bool hasFrameBuffer = nullptr != renderTask.GetFrameBuffer();
const bool isDefaultRenderTask = isFirstRenderTask;
isFirstRenderTask = false;
* Constructor
*/
TransformManagerPropertyHandler()
- :mTxManager(0),
+ :mTxManager(nullptr),
mId( INVALID_TRANSFORM_ID )
{}
* Create an TransformManagerVector3Input
*/
TransformManagerVector3Input( TransformManagerProperty property, const Vector3& initialValue )
- :mTxManager(0),
+ :mTxManager(nullptr),
mId(INVALID_TRANSFORM_ID),
mProperty(property),
mValue(initialValue)
* Constructor
*/
TransformManagerQuaternionInput()
- :mTxManager(0),
+ :mTxManager(nullptr),
mId(INVALID_TRANSFORM_ID),
mValue(1.0f,0.0f,0.0f,0.0f)
{
* Constructor
*/
TransformManagerMatrixInput()
- :mTxManager(0),
+ :mTxManager(nullptr),
mId(INVALID_TRANSFORM_ID)
{
}
*/
Matrix& Get( BufferIndex bufferIndex )
{
- DALI_ASSERT_ALWAYS( mTxManager != 0 );
+ DALI_ASSERT_ALWAYS( mTxManager != nullptr );
return mTxManager->GetWorldMatrix(mId);
}
transformManager(),
animationPlaylist( animationPlaylist ),
propertyNotifier( propertyNotifier ),
- shaderSaver( NULL ),
+ shaderSaver( nullptr ),
discardQueue( discardQueue ),
renderController( renderController ),
- sceneController( NULL ),
+ sceneController( nullptr ),
renderManager( renderManager ),
renderQueue( renderQueue ),
renderTaskProcessor( renderTaskProcessor ),
renderers(),
textureSets(),
shaders(),
- panGestureProcessor( NULL ),
+ panGestureProcessor( nullptr ),
messageQueue( renderController, sceneGraphBuffers ),
- frameCallbackProcessor( NULL ),
+ frameCallbackProcessor( nullptr ),
keepRenderingSeconds( 0.0f ),
nodeDirtyFlags( NodePropertyFlags::TRANSFORM ), // set to TransformFlag to ensure full update the first time through Update()
frameCounter( 0 ),
sceneController = new SceneControllerImpl( renderMessageDispatcher, renderQueue, discardQueue );
// create first 'dummy' node
- nodes.PushBack(0u);
+ nodes.PushBack(nullptr);
}
~Impl()
RenderTaskList::RenderTaskContainer& tasks = scene->taskList->GetTasks();
for ( auto&& task : tasks )
{
- task->SetSourceNode( NULL );
+ task->SetSourceNode( nullptr );
}
}
}
RenderManager& renderManager,
RenderQueue& renderQueue,
RenderTaskProcessor& renderTaskProcessor )
- : mImpl(NULL)
+ : mImpl(nullptr)
{
mImpl = new Impl( notificationManager,
animationFinishedNotifier,
void UpdateManager::AddNode( OwnerPointer<Node>& node )
{
- DALI_ASSERT_ALWAYS( NULL == node->GetParent() ); // Should not have a parent yet
+ DALI_ASSERT_ALWAYS( nullptr == node->GetParent() ); // Should not have a parent yet
// Nodes must be sorted by pointer
Node* rawNode = node.Release();
void UpdateManager::ConnectNode( Node* parent, Node* node )
{
- DALI_ASSERT_ALWAYS( NULL != parent );
- DALI_ASSERT_ALWAYS( NULL != node );
- DALI_ASSERT_ALWAYS( NULL == node->GetParent() ); // Should not have a parent yet
+ DALI_ASSERT_ALWAYS( nullptr != parent );
+ DALI_ASSERT_ALWAYS( nullptr != node );
+ DALI_ASSERT_ALWAYS( nullptr == node->GetParent() ); // Should not have a parent yet
DALI_LOG_INFO( gLogFilter, Debug::General, "[%x] ConnectNode\n", node );
DALI_LOG_INFO( gLogFilter, Debug::General, "[%x] DisconnectNode\n", node );
Node* parent = node->GetParent();
- DALI_ASSERT_ALWAYS( NULL != parent );
+ DALI_ASSERT_ALWAYS( nullptr != parent );
parent->SetDirtyFlag( NodePropertyFlags::CHILD_DELETED ); // make parent dirty so that render items dont get reused
parent->DisconnectChild( mSceneGraphBuffers.GetUpdateBufferIndex(), *node );
void UpdateManager::DestroyNode( Node* node )
{
- DALI_ASSERT_ALWAYS( NULL != node );
- DALI_ASSERT_ALWAYS( NULL == node->GetParent() ); // Should have been disconnected
+ DALI_ASSERT_ALWAYS( nullptr != node );
+ DALI_ASSERT_ALWAYS( nullptr == node->GetParent() ); // Should have been disconnected
DALI_LOG_INFO( gLogFilter, Debug::General, "[%x] DestroyNode\n", node );
SceneGraph::Node* FindNodeInSceneGraph( uint32_t id, SceneGraph::Node& node )
{
- SceneGraph::Node* matchingNode = NULL;
+ SceneGraph::Node* matchingNode = nullptr;
if( node.mId == id )
{
UpdateProxy::UpdateProxy( SceneGraph::UpdateManager& updateManager, SceneGraph::TransformManager& transformManager, SceneGraph::Node& rootNode )
: mNodeContainer(),
- mLastCachedIdNodePair( { 0u, NULL } ),
+ mLastCachedIdNodePair( { 0u, nullptr } ),
mCurrentBufferIndex( 0u ),
mUpdateManager( updateManager ),
mTransformManager( transformManager ),
void UpdateProxy::NodeHierarchyChanged()
{
- mLastCachedIdNodePair = { 0u, NULL };
+ mLastCachedIdNodePair = { 0u, nullptr };
mNodeContainer.clear();
mPropertyModifier.reset();
}
SceneGraph::Node* UpdateProxy::GetNodeWithId( uint32_t id ) const
{
- SceneGraph::Node* node = NULL;
+ SceneGraph::Node* node = nullptr;
// Cache the last accessed node so we don't have to traverse
if( mLastCachedIdNodePair.node && mLastCachedIdNodePair.id == id )
}
Node::Node()
-: mTransformManager( NULL ),
+: mTransformManager( nullptr ),
mTransformId( INVALID_TRANSFORM_ID ),
mParentOrigin( TRANSFORM_PROPERTY_PARENT_ORIGIN ),
mAnchorPoint( TRANSFORM_PROPERTY_ANCHOR_POINT ),
mWorldColor( Color::WHITE ),
mClippingSortModifier( 0u ),
mId( ++mNodeCounter ),
- mParent( NULL ),
- mExclusiveRenderTask( NULL ),
+ mParent( nullptr ),
+ mExclusiveRenderTask( nullptr ),
mChildren(),
mClippingDepth( 0u ),
mScissorDepth( 0u ),
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 );
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 )
break; // iter is no longer valid
}
}
- DALI_ASSERT_ALWAYS( NULL != found );
+ DALI_ASSERT_ALWAYS( nullptr != found );
found->RecursiveDisconnectFromSceneGraph( updateBufferIndex );
}
{
DALI_ASSERT_ALWAYS(this != &parentNode);
DALI_ASSERT_ALWAYS(!mIsRoot);
- DALI_ASSERT_ALWAYS(mParent == NULL);
+ DALI_ASSERT_ALWAYS(mParent == nullptr);
mParent = &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 )
PropertyOwner::DisconnectFromSceneGraph( updateBufferIndex );
// Remove back-pointer to parent
- mParent = NULL;
+ mParent = nullptr;
// Remove all child pointers
mChildren.Clear();
*/
virtual Layer* GetLayer()
{
- return NULL;
+ return nullptr;
}
/**
template <>
inline void OwnerPointer<Dali::Internal::SceneGraph::Node>::Reset()
{
- if (mObject != NULL)
+ if (mObject != nullptr)
{
Dali::Internal::SceneGraph::Node::Delete(mObject);
- mObject = NULL;
+ mObject = nullptr;
}
}
} // namespace Internal
: Node(),
mSortFunction( Internal::Layer::ZValue ),
mClippingBox( 0,0,0,0 ),
- mLastCamera( NULL ),
+ mLastCamera( nullptr ),
mBehavior( Dali::Layer::LAYER_UI ),
mIsClipping( false ),
mDepthTestDisabled( true ),
struct Renderable
{
Renderable()
- : mNode( 0 ),
- mRenderer( 0 )
+ : mNode( nullptr ),
+ mRenderer( nullptr )
{}
Renderable( Node* node, Renderer* renderer )
template <>
inline void OwnerPointer<Dali::Internal::SceneGraph::Layer>::Reset()
{
- if (mObject != NULL)
+ if (mObject != nullptr)
{
Dali::Internal::SceneGraph::Node::Delete(mObject);
- mObject = NULL;
+ mObject = nullptr;
}
}
} // namespace Internal
queueWasEmpty(true),
sceneUpdateFlag( false ),
sceneUpdate( 0 ),
- currentMessageBuffer(NULL)
+ currentMessageBuffer(nullptr)
{
}
};
MessageQueue::MessageQueue( Integration::RenderController& controller, const SceneGraph::SceneGraphBuffers& buffers )
-: mImpl(NULL)
+: mImpl(nullptr)
{
mImpl = new Impl( controller, buffers );
}
// Called from event thread
bool MessageQueue::FlushQueue()
{
- const bool messagesToProcess = ( NULL != mImpl->currentMessageBuffer );
+ const bool messagesToProcess = ( nullptr != mImpl->currentMessageBuffer );
// If there're messages to flush
if ( messagesToProcess )
MessageQueueMutex::ScopedLock lock( mImpl->queueMutex );
mImpl->processQueue.push_back( mImpl->currentMessageBuffer );
- mImpl->currentMessageBuffer = NULL;
+ mImpl->currentMessageBuffer = nullptr;
// Grab any recycled MessageBuffers
while ( !mImpl->recycleQueue.empty() )
Camera::Camera()
: mUpdateViewFlag( UPDATE_COUNT ),
mUpdateProjectionFlag( UPDATE_COUNT ),
- mNode( NULL ),
+ mNode( nullptr ),
mType( DEFAULT_TYPE ),
mProjectionMode( DEFAULT_MODE ),
mInvertYAxis( DEFAULT_INVERT_Y_AXIS ),
}
RenderTaskList::RenderTaskList()
-: mNotificationObject( NULL ),
- mRenderMessageDispatcher( NULL )
+: mNotificationObject( nullptr ),
+ mRenderMessageDispatcher( nullptr )
{
}
mSourceNode( nullptr ),
mCameraNode( nullptr ),
mCamera( nullptr ),
- mFrameBuffer(0),
+ mFrameBuffer(nullptr),
mRefreshRate( Dali::RenderTask::DEFAULT_REFRESH_RATE ),
mFrameCounter( 0u ),
mRenderedOnceCounter( 0u ),
}
Renderer::Renderer()
-: mSceneController( 0 ),
- mRenderer( NULL ),
- mTextureSet( NULL ),
- mGeometry( NULL ),
- mShader( NULL ),
- mRenderDataProvider( NULL ),
- mBlendColor( NULL ),
+: mSceneController( nullptr ),
+ mRenderer( nullptr ),
+ mTextureSet( nullptr ),
+ mGeometry( nullptr ),
+ mShader( nullptr ),
+ mRenderDataProvider( nullptr ),
+ mBlendColor( nullptr ),
mStencilParameters( RenderMode::AUTO, StencilFunction::ALWAYS, 0xFF, 0x00, 0xFF, StencilOperation::KEEP, StencilOperation::KEEP, StencilOperation::KEEP ),
mIndexedDrawFirstElement( 0u ),
mIndexedDrawElementsCount( 0u ),
if( mTextureSet )
{
mTextureSet->RemoveObserver( this );
- mTextureSet = NULL;
+ mTextureSet = nullptr;
}
if( mShader )
{
mShader->RemoveConnectionObserver( *this );
- mShader = NULL;
+ mShader = nullptr;
}
}
{
if( blendColor == Color::TRANSPARENT )
{
- mBlendColor = NULL;
+ mBlendColor = nullptr;
}
else
{
if( mRenderer )
{
mSceneController->GetRenderMessageDispatcher().RemoveRenderer( *mRenderer );
- mRenderer = NULL;
+ mRenderer = nullptr;
}
- mSceneController = NULL;
- mRenderDataProvider = NULL;
+ mSceneController = nullptr;
+ mRenderDataProvider = nullptr;
}
void Renderer::UpdateTextureSet()
void Renderer::TextureSetDeleted()
{
- mTextureSet = NULL;
+ mTextureSet = nullptr;
mRegenerateUniformMap = REGENERATE_UNIFORM_MAP;
{
if( reinterpret_cast<PropertyOwner*>(mShader) == &owner )
{
- mShader = NULL;
+ mShader = nullptr;
}
}
mSamplers.Resize( index + 1 );
for( uint32_t i(samplerCount); i<=index; ++i )
{
- mSamplers[i] = NULL;
+ mSamplers[i] = nullptr;
}
}
for( uint32_t i(textureCount); i<=index; ++i )
{
- mTextures[i] = 0;
+ mTextures[i] = nullptr;
if( !samplerExist )
{
- mSamplers[i] = 0;
+ mSamplers[i] = nullptr;
}
}
}
}
CustomActorImpl::CustomActorImpl( ActorFlags flags )
-: mOwner(NULL),
+: mOwner(nullptr),
mFlags( flags )
{
}
*/
virtual Extension* GetExtension()
{
- return NULL;
+ return nullptr;
}
protected: // For derived classes
AlphaFunction::AlphaFunction()
:mBezierControlPoints(Vector4::ZERO),
- mCustom(0),
+ mCustom(nullptr),
mBuiltin(DEFAULT),
mMode(BUILTIN_FUNCTION)
{}
AlphaFunction::AlphaFunction( BuiltinFunction function)
:mBezierControlPoints(Vector4::ZERO),
- mCustom(0),
+ mCustom(nullptr),
mBuiltin(function),
mMode(BUILTIN_FUNCTION)
{}
AlphaFunction::AlphaFunction( const Vector2& controlPoint0, const Vector2& controlPoint1 )
:mBezierControlPoints(Vector4(Clamp(controlPoint0.x,0.0f,1.0f),controlPoint0.y,
Clamp(controlPoint1.x,0.0f,1.0f),controlPoint1.y)),
- mCustom(0),
+ mCustom(nullptr),
mBuiltin(DEFAULT),
mMode(BEZIER)
{
template< class T >
Function( const T& object )
: CallbackBase( reinterpret_cast< void* >( new T( object ) ), // copy the object
- NULL, // uses operator() instead of member function
+ nullptr, // uses operator() instead of member function
reinterpret_cast< CallbackBase::Dispatcher >( &FunctorDispatcher2< T, P&, const PropertyInputContainer& >::Dispatch ),
reinterpret_cast< CallbackBase::Destructor >( &Destroyer< T >::Delete ) ),
mCopyConstructorDispatcher( reinterpret_cast< CopyConstructorDispatcher >( &ObjectCopyConstructorDispatcher< T >::Copy ) )
*/
CallbackBase* Clone()
{
- CallbackBase* callback = NULL;
+ CallbackBase* callback = nullptr;
if ( mImpl && mImpl->mObjectPointer && mCopyConstructorDispatcher )
{
callback = new Function( mCopyConstructorDispatcher( reinterpret_cast< UndefinedClass* >( mImpl->mObjectPointer ) ) /* Copy the object */,
*/
Function( CallbackBase::Function function )
: CallbackBase( function ),
- mCopyConstructorDispatcher( NULL )
+ mCopyConstructorDispatcher( nullptr )
{
}
{
VectorBase::VectorBase()
- : mData( NULL )
+ : mData( nullptr )
{
}
SizeType* metadata = reinterpret_cast< SizeType* >( mData );
delete [] ( metadata - 2u );
- mData = 0u;
+ mData = nullptr;
}
}
char* VectorBase::Erase( char* first, char* last, SizeType elementSize )
{
- char* next = NULL;
+ char* next = nullptr;
if( mData )
{
* @brief Standard constructor to unassigned object.
* @SINCE_1_0.0
*/
- IntrusivePtr() : mPtr( 0 ) {}
+ IntrusivePtr() : mPtr( nullptr ) {}
/**
* @brief Constructor to attach existing object.
*/
operator BooleanType() const
{
- return mPtr ? &IntrusivePtr::ThisIsSaferThanReturningVoidStar : 0;
+ return mPtr ? &IntrusivePtr::ThisIsSaferThanReturningVoidStar : nullptr;
}
/**
T* Detach()
{
T* ptr = mPtr;
- mPtr = 0;
+ mPtr = nullptr;
return ptr;
}
*/
virtual Extension* GetExtension()
{
- return NULL;
+ return nullptr;
}
protected:
static bool initialized( false );
if( !initialized )
{
- uint32_t seed = static_cast<uint32_t>( time( NULL ) );
+ uint32_t seed = static_cast<uint32_t>( time( nullptr ) );
srand( seed );
initialized = true;
}
{
Any::Any()
-: mContainer( NULL )
+: mContainer( nullptr )
{
}
{
// Call the implementation deletion function, which will invalidate mContainer
- if ( NULL != mContainer )
+ if ( nullptr != mContainer )
{
mContainer->mDeleteFunc( mContainer );
- mContainer = NULL;
+ mContainer = nullptr;
}
}
{
if( &any != this )
{
- if( NULL == any.mContainer )
+ if( nullptr == any.mContainer )
{
delete mContainer;
- mContainer = NULL;
+ mContainer = nullptr;
}
else
{
AnyContainerBase* tmp = mContainer;
- if( NULL != mContainer )
+ if( nullptr != mContainer )
{
// Check if two Any types have the same type. Avoids assignments of values with different types.
if( mContainer->GetType() != any.GetType() )
Any( const Any& any )
{
// If container isn't empty then copy the container?
- if ( NULL != any.mContainer )
+ if ( nullptr != any.mContainer )
{
mContainer = any.mContainer->mCloneFunc( *any.mContainer );
}
else
{
// Otherwise mark new container as empty
- mContainer = NULL;
+ mContainer = nullptr;
}
}
Any& operator=( const Type& value )
{
// If the container is empty then assign the new value
- if ( NULL == mContainer )
+ if ( nullptr == mContainer )
{
mContainer = new AnyContainerImpl< Type >( value );
}
template<typename Type>
const Type& Get() const
{
- if ( NULL == mContainer )
+ if ( nullptr == mContainer )
{
AssertAlways( "Any::Get(). mContainer is NULL" );
}
template<typename Type>
Type* GetPointer()
{
- if( NULL == mContainer )
+ if( nullptr == mContainer )
{
return NULL;
}
template<typename Type>
const Type* GetPointer() const
{
- if( NULL == mContainer )
+ if( nullptr == mContainer )
{
return NULL;
}
*/
bool Empty() const
{
- return ( NULL == mContainer ) ? true : false;
+ return ( nullptr == mContainer ) ? true : false;
}
struct AnyContainerBase; // Forward declaration for typedef
void BaseHandle::Reset()
{
- mObjectHandle = NULL;
+ mObjectHandle = nullptr;
}
BaseHandle::operator BaseHandle::BooleanType() const
{
- return mObjectHandle ? &BaseHandle::ThisIsSaferThanReturningVoidStar : NULL;
+ return mObjectHandle ? &BaseHandle::ThisIsSaferThanReturningVoidStar : nullptr;
}
bool BaseHandle::operator==(const BaseHandle& rhs) const
*/
virtual Extension* GetExtension()
{
- return NULL;
+ return nullptr;
}
};
return &iter.second;
}
}
- return NULL; // Not found
+ return nullptr; // Not found
}
Property::Value* Property::Map::Find( const std::string& key ) const
return &iter.second;
}
}
- return NULL; // Not found
+ return nullptr; // Not found
}
Property::Value* Property::Map::Find( Property::Index indexKey, const std::string& stringKey ) const
return &iter.second;
}
}
- return NULL; // Not found
+ return nullptr; // Not found
}
Property::Value* Property::Map::Find( Property::Index key, Property::Type type ) const
return &iter.second;
}
}
- return NULL; // Not found
+ return nullptr; // Not found
}
void Property::Map::Clear()
void RenderTask::SetSourceActor( Actor actor )
{
// NULL handle is allowed
- Internal::Actor* actorImpl( NULL );
+ Internal::Actor* actorImpl( nullptr );
if ( actor )
{
actorImpl = &GetImplementation( actor );
void RenderTask::SetCameraActor( CameraActor cameraActor )
{
// NULL handle is allowed
- Internal::CameraActor* actorImpl( NULL );
+ Internal::CameraActor* actorImpl( nullptr );
if ( cameraActor )
{
actorImpl = &GetImplementation( cameraActor );
void RenderTask::SetFrameBuffer( FrameBuffer frameBuffer )
{
- Internal::FrameBuffer* frameBufferPtr( NULL );
+ Internal::FrameBuffer* frameBufferPtr( nullptr );
if( frameBuffer )
{
frameBufferPtr = &GetImplementation( frameBuffer );
}
else
{
- GetImplementation(*this).SetTexture( static_cast<uint32_t>( index ), NULL ); // only support 4,294,967,295 textures
+ GetImplementation(*this).SetTexture( static_cast<uint32_t>( index ), nullptr ); // only support 4,294,967,295 textures
}
}
}
else
{
- GetImplementation(*this).SetSampler( static_cast<uint32_t>( index ), NULL ); // only support 4,294,967,295 samplers
+ GetImplementation(*this).SetSampler( static_cast<uint32_t>( index ), nullptr ); // only support 4,294,967,295 samplers
}
}
for( std::size_t i = 0; i < size; ++i )
{
// Note that values are set to NULL in DeleteConnection
- if ( NULL != mSignalConnections[i] )
+ if ( nullptr != mSignalConnections[i] )
{
++count;
}
void BaseSignal::OnConnect( CallbackBase* callback )
{
- DALI_ASSERT_ALWAYS( NULL != callback && "Invalid member function pointer passed to Connect()" );
+ DALI_ASSERT_ALWAYS( nullptr != callback && "Invalid member function pointer passed to Connect()" );
int32_t index = FindCallback( callback );
void BaseSignal::OnDisconnect( CallbackBase* callback )
{
- DALI_ASSERT_ALWAYS( NULL != callback && "Invalid member function pointer passed to Disconnect()" );
+ DALI_ASSERT_ALWAYS( nullptr != callback && "Invalid member function pointer passed to Disconnect()" );
int32_t index = FindCallback( callback );
void BaseSignal::OnConnect( ConnectionTrackerInterface* tracker, CallbackBase* callback )
{
- DALI_ASSERT_ALWAYS( NULL != tracker && "Invalid ConnectionTrackerInterface pointer passed to Connect()" );
- DALI_ASSERT_ALWAYS( NULL != callback && "Invalid member function pointer passed to Connect()" );
+ DALI_ASSERT_ALWAYS( nullptr != tracker && "Invalid ConnectionTrackerInterface pointer passed to Connect()" );
+ DALI_ASSERT_ALWAYS( nullptr != callback && "Invalid member function pointer passed to Connect()" );
int32_t index = FindCallback( callback );
void BaseSignal::OnDisconnect( ConnectionTrackerInterface* tracker, CallbackBase* callback )
{
- DALI_ASSERT_ALWAYS( NULL != tracker && "Invalid ConnectionTrackerInterface pointer passed to Disconnect()" );
- DALI_ASSERT_ALWAYS( NULL != callback && "Invalid member function pointer passed to Disconnect()" );
+ DALI_ASSERT_ALWAYS( nullptr != tracker && "Invalid ConnectionTrackerInterface pointer passed to Disconnect()" );
+ DALI_ASSERT_ALWAYS( nullptr != callback && "Invalid member function pointer passed to Disconnect()" );
int32_t index = FindCallback( callback );
{
DALI_ASSERT_ALWAYS( connectionIndex < mSignalConnections.Count() && "GetCallback called with invalid index" );
- CallbackBase* callback( NULL );
+ CallbackBase* callback( nullptr );
SignalConnection* connection( mSignalConnections[ connectionIndex ] );
// IMPORTANT - do not remove from items from mSignalConnections, set to NULL instead.
// Signal Emit() methods require that connection count is not reduced while iterating
// i.e. DeleteConnection can be called from within callbacks, while iterating through mSignalConnections.
- mSignalConnections[ connectionIndex ] = NULL;
+ mSignalConnections[ connectionIndex ] = nullptr;
}
else
{
// process the whole vector
for( std::size_t i = 0; i < total; ++i )
{
- if( mSignalConnections[ index ] == NULL )
+ if( mSignalConnections[ index ] == nullptr )
{
// items will be moved so don't increase index (erase will decrease the count of vector)
mSignalConnections.Erase( mSignalConnections.Begin() + index );
// BaseSignal::EmitGuard
BaseSignal::EmitGuard::EmitGuard( bool& flag )
-: mFlag( NULL )
+: mFlag( nullptr )
{
if( !flag )
{
bool BaseSignal::EmitGuard::ErrorOccurred()
{
// mFlag is NULL when Emit() is called during Emit()
- return (NULL == mFlag);
+ return (nullptr == mFlag);
}
} // namespace Dali
// CallbackBase
CallbackBase::CallbackBase()
-: mImpl( NULL ),
- mFunction( NULL )
+: mImpl( nullptr ),
+ mFunction( nullptr )
{
}
}
CallbackBase::CallbackBase( Function function )
-: mImpl( NULL ),
+: mImpl( nullptr ),
mFunction( function )
{
}
{
mImpl->mObjectPointer = object;
mImpl->mMemberFunctionDispatcher = dispatcher;
- mImpl->mDestructorDispatcher = NULL; // object is not owned
+ mImpl->mDestructorDispatcher = nullptr; // object is not owned
}
}
}
delete mImpl;
- mImpl = NULL;
+ mImpl = nullptr;
}
- mFunction = NULL;
+ mFunction = nullptr;
}
// CallbackBase::Impl
CallbackBase::Impl::Impl()
-: mObjectPointer( NULL ),
- mMemberFunctionDispatcher( NULL ),
- mDestructorDispatcher( NULL )
+: mObjectPointer( nullptr ),
+ mMemberFunctionDispatcher( nullptr ),
+ mDestructorDispatcher( nullptr )
{
}
}
SignalConnection::SignalConnection( CallbackBase* callback )
-: mSignalObserver( NULL ),
+: mSignalObserver( nullptr ),
mCallback( callback )
{
}
{
// tell the slot the signal wants to disconnect
mSignalObserver->SignalDisconnected( slotObserver, mCallback );
- mSignalObserver = NULL;
+ mSignalObserver = nullptr;
}
// we own the callback, SignalObserver is expected to delete the SlotConnection on Disconnected so its pointer to our mCallback is no longer used
delete mCallback;
- mCallback = NULL;
+ mCallback = nullptr;
}
CallbackBase* SignalConnection::GetCallback()