X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=dali-toolkit%2Finternal%2Fvisuals%2Fnpatch%2Fnpatch-visual.h;h=e178eb868a134fce0ee3e26a348aef3a011ab222;hb=44835162f4c0107591223e60557ee62b79cab35a;hp=a9933036c2845bc3f78ba132cdb8523218863e38;hpb=b81c20064def5a5017e77876effd01ddc5bb39d6;p=platform%2Fcore%2Fuifw%2Fdali-toolkit.git diff --git a/dali-toolkit/internal/visuals/npatch/npatch-visual.h b/dali-toolkit/internal/visuals/npatch/npatch-visual.h index a993303..e178eb8 100644 --- a/dali-toolkit/internal/visuals/npatch/npatch-visual.h +++ b/dali-toolkit/internal/visuals/npatch/npatch-visual.h @@ -24,7 +24,7 @@ // EXTERNAL INCLUDES #include #include -#include +#include #include #include #include @@ -61,6 +61,26 @@ public: NPatchVisual( VisualFactoryCache& factoryCache ); /** + * @brief Constructor which creates an N-patch visual using an image URL. + * + * The visual will load the image synchronously when the associated actor is put on stage, and destroy the image when it is off stage + * + * @param[in] factoryCache A pointer pointing to the VisualFactoryCache object + * @param[in] imageUrl The URL to 9 patch image resource to use + * @param[in] borderOnly A Flag to indicate if the image should omit the centre of the n-patch and only render the border + */ + NPatchVisual( VisualFactoryCache& factoryCache, const std::string& imageUrl, bool borderOnly = false ); + + /** + * @brief Constructor which creates an N-patch viusal with a NinePatchImage resource. + * + * @param[in] factoryCache A pointer pointing to the VisualFactoryCache object + * @param[in] image The NinePatchImage to use + * @param[in] borderOnly A Flag to indicate if the image should omit the centre of the n-patch and only render the border + */ + NPatchVisual( VisualFactoryCache& factoryCache, NinePatchImage image, bool borderOnly = false ); + + /** * @brief A reference counted object may only be deleted by calling Unreference(). */ ~NPatchVisual(); @@ -77,6 +97,16 @@ public: // from Visual */ virtual void DoCreatePropertyMap( Property::Map& map ) const; + /** + * @copydoc Visual::Base::DoSetProperty + */ + virtual void DoSetProperty( Dali::Property::Index index, const Dali::Property::Value& propertyValue ); + + /** + * @copydoc Visual::Base::DoGetProperty + */ + virtual Dali::Property::Value DoGetProperty( Dali::Property::Index index ); + protected: /** @@ -94,25 +124,6 @@ protected: */ virtual void DoSetOffStage( Actor& actor ); -public: - - /** - * @brief Sets the 9 patch image of this visual to the resource at imageUrl - * The visual will load the image synchronously when the associated actor is put on stage, and destroy the image when it is off stage - * - * @param[in] imageUrl The URL to 9 patch image resource to use - * @param[in] borderOnly A Flag to indicate if the image should omit the centre of the n-patch and only render the border - */ - void SetImage( const std::string& imageUrl, bool borderOnly = false ); - - /** - * @brief Sets the 9 patch image of this viusal to the 9 patch image - * - * @param[in] image The NinePatchImage to use - * @param[in] borderOnly A Flag to indicate if the image should omit the centre of the n-patch and only render the border - */ - void SetImage( NinePatchImage image, bool borderOnly = false ); - private: /**