namespace Toolkit
{
-namespace Visual
-{
-
-Base::Base()
+Visual::Base::Base()
{
}
-Base::~Base()
+Visual::Base::~Base()
{
}
-Base::Base( const Base& handle )
+Visual::Base::Base( const Visual::Base& handle )
: BaseHandle( handle )
{
}
-Base& Base::operator=( const Base& handle )
+Visual::Base& Visual::Base::operator=( const Visual::Base& handle )
{
BaseHandle::operator=( handle );
return *this;
}
-Base::Base(Internal::Visual::Base *impl)
+Visual::Base::Base(Internal::Visual::Base *impl)
: BaseHandle( impl )
{
}
-void Base::SetSize( const Vector2& size )
+void Visual::Base::SetSize( const Vector2& size )
{
GetImplementation( *this ).SetSize( size );
}
-const Vector2& Base::GetSize() const
+const Vector2& Visual::Base::GetSize() const
{
return GetImplementation( *this ).GetSize();
}
-void Base::GetNaturalSize(Vector2& naturalSize ) const
+void Visual::Base::GetNaturalSize(Vector2& naturalSize ) const
{
GetImplementation( *this ).GetNaturalSize( naturalSize );
}
-void Base::SetDepthIndex( float index )
+void Visual::Base::SetDepthIndex( float index )
{
GetImplementation( *this ).SetDepthIndex( index );
}
-float Base::GetDepthIndex() const
+float Visual::Base::GetDepthIndex() const
{
return GetImplementation( *this ).GetDepthIndex();
}
-void Base::SetOnStage( Actor& actor )
+void Visual::Base::SetOnStage( Actor& actor )
{
GetImplementation( *this ).SetOnStage( actor );
}
-void Base::SetOffStage( Actor& actor )
+void Visual::Base::SetOffStage( Actor& actor )
{
GetImplementation( *this ).SetOffStage( actor );
}
-void Base::RemoveAndReset( Actor& actor )
+void Visual::Base::RemoveAndReset( Actor& actor )
{
if( actor && *this )
{
Reset();
}
-void Base::CreatePropertyMap( Property::Map& map ) const
+void Visual::Base::CreatePropertyMap( Property::Map& map ) const
{
GetImplementation( *this ).CreatePropertyMap( map );
}
-} // namespace Visual
-
} // namespace Toolkit
} // namespace Dali
}
}
-void BorderVisual::SetClipRect( const Rect<int>& clipRect )
-{
- Visual::Base::SetClipRect( clipRect );
-
- //ToDo: renderer responds to the clipRect change
-}
-
void BorderVisual::DoSetOnStage( Actor& actor )
{
InitializeRenderer();
*/
virtual ~BorderVisual();
-public: // from Visual
-
- /**
- * @copydoc Visual::SetClipRect
- */
- virtual void SetClipRect( const Rect<int>& clipRect );
-
protected:
/**
// ToDo: renderer responds to the size change
}
-void ColorVisual::SetClipRect( const Rect<int>& clipRect )
-{
- Visual::Base::SetClipRect( clipRect );
-
- //ToDo: renderer responds to the clipRect change
-}
-
-void ColorVisual::SetOffset( const Vector2& offset )
-{
- //ToDo: renderer applies the offset
-}
-
void ColorVisual::DoSetOnStage( Actor& actor )
{
InitializeRenderer();
virtual void SetSize( const Vector2& size );
/**
- * @copydoc Visual::SetClipRect
- */
- virtual void SetClipRect( const Rect<int>& clipRect );
-
- /**
- * @copydoc Visual::SetOffset
- */
- virtual void SetOffset( const Vector2& offset );
-
- /**
* @copydoc Visual::CreatePropertyMap
*/
virtual void DoCreatePropertyMap( Property::Map& map ) const;
Visual::Base::SetSize( size );
}
-void GradientVisual::SetClipRect( const Rect<int>& clipRect )
-{
- Visual::Base::SetClipRect( clipRect );
-
- //ToDo: renderer responds to the clipRect change
-}
-
-void GradientVisual::SetOffset( const Vector2& offset )
-{
- //ToDo: renderer applies the offset
-}
-
void GradientVisual::DoSetOnStage( Actor& actor )
{
InitializeRenderer();
virtual void SetSize( const Vector2& size );
/**
- * @copydoc Visual::SetClipRect
- */
- virtual void SetClipRect( const Rect<int>& clipRect );
-
- /**
- * @copydoc Visual::SetOffset
- */
- virtual void SetOffset( const Vector2& offset );
-
- /**
* @copydoc Visual::CreatePropertyMap
*/
virtual void DoCreatePropertyMap( Property::Map& map ) const;
naturalSize = Vector2::ZERO;
}
-void BatchImageVisual::SetClipRect( const Rect<int>& clipRect )
-{
- Visual::Base::SetClipRect( clipRect );
-}
-
void BatchImageVisual::InitializeRenderer( const std::string& imageUrl )
{
if( imageUrl.empty() )
virtual void GetNaturalSize( Vector2& naturalSize ) const;
/**
- * @copydoc Visual::Base::SetClipRect
- */
- virtual void SetClipRect( const Rect<int>& clipRect );
-
- /**
* @copydoc Visual::Base::CreatePropertyMap
*/
virtual void DoCreatePropertyMap( Property::Map& map ) const;
// ToDo: renderer responds to the size change
}
-void MeshVisual::SetClipRect( const Rect<int>& clipRect )
-{
- Visual::Base::SetClipRect( clipRect );
-
- //ToDo: renderer responds to the clipRect change
-}
-
-void MeshVisual::SetOffset( const Vector2& offset )
-{
- //ToDo: renderer applies the offset
-}
-
void MeshVisual::DoSetOnStage( Actor& actor )
{
InitializeRenderer();
virtual void SetSize( const Vector2& size );
/**
- * @copydoc Visual::SetClipRect
- */
- virtual void SetClipRect( const Rect<int>& clipRect );
-
- /**
- * @copydoc Visual::SetOffset
- */
- virtual void SetOffset( const Vector2& offset );
-
- /**
* @copydoc Visual::CreatePropertyMap
*/
virtual void DoCreatePropertyMap( Property::Map& map ) const;
}
}
-void NPatchVisual::SetClipRect( const Rect<int>& clipRect )
-{
- Visual::Base::SetClipRect( clipRect );
- //ToDo: renderer responds to the clipRect change
-}
-
-void NPatchVisual::SetOffset( const Vector2& offset )
-{
- //ToDo: renderer applies the offset
-}
-
Geometry NPatchVisual::CreateGeometry()
{
Geometry geometry;
virtual void GetNaturalSize( Vector2& naturalSize ) const;
/**
- * @copydoc Visual::SetClipRect
- */
- virtual void SetClipRect( const Rect<int>& clipRect );
-
- /**
- * @copydoc Visual::SetOffset
- */
- virtual void SetOffset( const Vector2& offset );
-
- /**
* @copydoc Visual::CreatePropertyMap
*/
virtual void DoCreatePropertyMap( Property::Map& map ) const;
naturalSize.y = mObjectDimensions.y;
}
-void PrimitiveVisual::SetClipRect( const Rect<int>& clipRect )
-{
- Visual::Base::SetClipRect( clipRect );
-
- //ToDo: renderer responds to the clipRect change
-}
-
-void PrimitiveVisual::SetOffset( const Vector2& offset )
-{
- //ToDo: renderer applies the offset
-}
-
void PrimitiveVisual::DoSetOnStage( Actor& actor )
{
InitializeRenderer();
virtual void GetNaturalSize( Vector2& naturalSize ) const;
/**
- * @copydoc Visual::SetClipRect
- */
- virtual void SetClipRect( const Rect<int>& clipRect );
-
- /**
- * @copydoc Visual::SetOffset
- */
- virtual void SetOffset( const Vector2& offset );
-
- /**
* @copydoc Visual::CreatePropertyMap
*/
virtual void DoCreatePropertyMap( Property::Map& map ) const;
CustomShader* mCustomShader;
Vector2 mSize;
- Vector2 mOffset;
float mDepthIndex;
int mFlags;
namespace Internal
{
-namespace Visual
-{
-
-Base::Base( VisualFactoryCache& factoryCache )
+Visual::Base::Base( VisualFactoryCache& factoryCache )
: mImpl( new Impl() ),
mFactoryCache( factoryCache )
{
}
-Base::~Base()
+Visual::Base::~Base()
{
delete mImpl;
}
-void Base::SetCustomShader( const Property::Map& shaderMap )
+void Visual::Base::SetCustomShader( const Property::Map& shaderMap )
{
if( mImpl->mCustomShader )
{
}
}
-void Base::Initialize( Actor& actor, const Property::Map& propertyMap )
+void Visual::Base::Initialize( Actor& actor, const Property::Map& propertyMap )
{
Property::Value* customShaderValue = propertyMap.Find( Toolkit::Visual::Property::SHADER, CUSTOM_SHADER );
if( customShaderValue )
DoInitialize( actor, propertyMap );
}
-void Base::SetSize( const Vector2& size )
+void Visual::Base::SetSize( const Vector2& size )
{
mImpl->mSize = size;
}
-const Vector2& Base::GetSize() const
+const Vector2& Visual::Base::GetSize() const
{
return mImpl->mSize;
}
-void Base::GetNaturalSize( Vector2& naturalSize ) const
+void Visual::Base::GetNaturalSize( Vector2& naturalSize ) const
{
naturalSize = Vector2::ZERO;
}
-void Base::SetClipRect( const Rect<int>& clipRect )
-{
-}
-
-void Base::SetOffset( const Vector2& offset )
-{
- mImpl->mOffset = offset;
-}
-
-void Base::SetDepthIndex( float index )
+void Visual::Base::SetDepthIndex( float index )
{
mImpl->mDepthIndex = index;
if( mImpl->mRenderer )
}
}
-float Base::GetDepthIndex() const
+float Visual::Base::GetDepthIndex() const
{
return mImpl->mDepthIndex;
}
-void Base::SetOnStage( Actor& actor )
+void Visual::Base::SetOnStage( Actor& actor )
{
DoSetOnStage( actor );
mImpl->mFlags |= Impl::IS_ON_STAGE;
}
-void Base::SetOffStage( Actor& actor )
+void Visual::Base::SetOffStage( Actor& actor )
{
if( GetIsOnStage() )
{
}
}
-void Base::EnablePreMultipliedAlpha( bool preMultipled )
+void Visual::Base::EnablePreMultipliedAlpha( bool preMultipled )
{
if(preMultipled)
{
}
}
-bool Base::IsPreMultipliedAlphaEnabled() const
+bool Visual::Base::IsPreMultipliedAlphaEnabled() const
{
return mImpl->mFlags & Impl::IS_PREMULTIPLIED_ALPHA;
}
-void Base::DoSetOnStage( Actor& actor )
+void Visual::Base::DoSetOnStage( Actor& actor )
{
}
-void Base::DoSetOffStage( Actor& actor )
+void Visual::Base::DoSetOffStage( Actor& actor )
{
actor.RemoveRenderer( mImpl->mRenderer );
mImpl->mRenderer.Reset();
}
-void Base::CreatePropertyMap( Property::Map& map ) const
+void Visual::Base::CreatePropertyMap( Property::Map& map ) const
{
DoCreatePropertyMap( map );
}
}
-bool Base::GetIsOnStage() const
+bool Visual::Base::GetIsOnStage() const
{
return mImpl->mFlags & Impl::IS_ON_STAGE;
}
-bool Base::GetIsFromCache() const
+bool Visual::Base::GetIsFromCache() const
{
return mImpl->mFlags & Impl::IS_FROM_CACHE;
}
-} // namespace Visual
-
} // namespace Internal
} // namespace Toolkit
virtual void GetNaturalSize( Vector2& naturalSize ) const;
/**
- * ToDo: Add this function to Toolkit::Visual when it is fully implemented.
- *
- * Set the clip rectangular of this visual.
- * The contents of the visual will not be visible outside this rectangular.
- *
- * @param [in] clipRect The clipping rectangular.
- */
- virtual void SetClipRect( const Rect<int>& clipRect );
-
- /**
- *ToDo: Add this function to Toolkit::Visual when it is fully implemented.
- *
- * Reposition this visual with a 2D offset.
- *
- * @param[in] offset The offset to reposition the visual.
- */
- virtual void SetOffset( const Vector2& offset );
-
- /**
* @copydoc Toolkit::Visual::Base::SetDepthIndex
*/
void SetDepthIndex( float index );