From b956a870076e15be1400378e3a07edcdf79001c1 Mon Sep 17 00:00:00 2001 From: Agnelo Vaz Date: Thu, 27 Jul 2017 18:39:48 +0100 Subject: [PATCH] Added Devel Animated with Default Property Reg macro Change-Id: Ib93c776adaae19cdc09bfa67f9840857ed25705f --- dali/devel-api/object/property-helper-devel.h | 22 +++++++++++++++------- 1 file changed, 15 insertions(+), 7 deletions(-) diff --git a/dali/devel-api/object/property-helper-devel.h b/dali/devel-api/object/property-helper-devel.h index 5a90149..8777056 100644 --- a/dali/devel-api/object/property-helper-devel.h +++ b/dali/devel-api/object/property-helper-devel.h @@ -31,18 +31,17 @@ Dali::PropertyRegistration DALI_TOKEN_PASTE( property, count ) ( typeRegistrationObject, text, objectNamespace:: develNamespace ::Property::enumIndex, Dali::Property::valueType, &objectType::SetProperty, &objectType::GetProperty ); \ DALI_COMPILE_TIME_ASSERT( ( objectNamespace:: develNamespace ::Property::enumIndex - objectNamespace::objectType::PROPERTY_START_INDEX ) == count ); -/** - * @copydoc DALI_DEVEL_PROPERTY_REGISTRATION_INTERNAL - */ #define DALI_DEVEL_PROPERTY_REGISTRATION_INTERNAL_READ_ONLY( count, typeRegistrationObject, objectNamespace, objectType, develNamespace, text, valueType, enumIndex ) \ Dali::PropertyRegistration DALI_TOKEN_PASTE( property, count ) ( typeRegistrationObject, text, objectNamespace:: develNamespace ::Property::enumIndex, Dali::Property::valueType, NULL, &objectType::GetProperty ); \ DALI_COMPILE_TIME_ASSERT( ( objectNamespace:: develNamespace ::Property::enumIndex - objectNamespace::objectType::PROPERTY_START_INDEX ) == count ); -/** - * @copydoc DALI_DEVEL_PROPERTY_REGISTRATION_INTERNAL - */ #define DALI_DEVEL_ANIMATABLE_PROPERTY_REGISTRATION_INTERNAL( count, typeRegistrationObject, objectNamespace, objectType, develNamespace, text, valueType, enumIndex) \ Dali::AnimatablePropertyRegistration DALI_TOKEN_PASTE( property, count ) ( typeRegistrationObject, text, objectNamespace:: develNamespace::Property::enumIndex, Dali::Property::valueType ); + +#define DALI_DEVEL_ANIMATABLE_PROPERTY_REGISTRATION_WITH_DEFAULT_INTERNAL( count, typeRegistrationObject, objectNamespace, objectType, text, value, enumIndex) \ + Dali::AnimatablePropertyRegistration DALI_TOKEN_PASTE( property, count ) ( typeRegistrationObject, text, objectNamespace::objectType::Property::enumIndex, value ); + + /** * @brief These macros are used to define properties for implementations of CustomActor. * @@ -105,12 +104,21 @@ DALI_DEVEL_PROPERTY_REGISTRATION_INTERNAL_READ_ONLY( __COUNTER__, typeRegistration, objectNamespace, objectType, DALI_TOKEN_PASTE( Devel, objectType ), text, valueType, enumIndex ) /** - * @copydoc DALI_DEVEL_PROPERTY_REGISTRATION_INTERNAL + * @copydoc DALI_DEVEL_PROPERTY_REGISTRATION * * @note Animatible property registration */ #define DALI_DEVEL_ANIMATABLE_PROPERTY_REGISTRATION( objectNamespace, objectType, text, valueType, enumIndex ) \ DALI_DEVEL_ANIMATABLE_PROPERTY_REGISTRATION_INTERNAL( __COUNTER__, typeRegistration, objectNamespace, objectType, DALI_TOKEN_PASTE( Devel, objectType ), text, valueType, enumIndex ) +/** + * @copydoc DALI_DEVEL_PROPERTY_REGISTRATION + * + * @note Animatible property registration with default value + * + */ +#define DALI_DEVEL_ANIMATABLE_PROPERTY_REGISTRATION_WITH_DEFAULT( objectNamespace, objectType, text, value, enumIndex ) \ + DALI_DEVEL_ANIMATABLE_PROPERTY_REGISTRATION_WITH_DEFAULT_INTERNAL( __COUNTER__, typeRegistration, objectNamespace, DALI_TOKEN_PASTE( Devel, objectType ) , text, value, enumIndex ) + #endif // __DALI_PROPERTY_HELPER_DEVEL_H__ -- 2.7.4