Property refactor in dali-toolkit: Core changes 41/36441/2
authorTom Robinson <tom.robinson@samsung.com>
Fri, 6 Mar 2015 10:10:56 +0000 (10:10 +0000)
committerTom Robinson <tom.robinson@samsung.com>
Fri, 6 Mar 2015 11:08:04 +0000 (11:08 +0000)
Change-Id: I775426aa1ce8018c9dcf41ff125935be1e9f6ccc

13 files changed:
dali/public-api/actors/actor.h
dali/public-api/actors/camera-actor.h
dali/public-api/actors/image-actor.h
dali/public-api/actors/layer.h
dali/public-api/actors/text-actor.h
dali/public-api/animation/active-constraint.h
dali/public-api/animation/path.h
dali/public-api/events/pan-gesture-detector.h
dali/public-api/file.list
dali/public-api/geometry/animatable-vertex.h
dali/public-api/object/type-registry-helper.h [new file with mode: 0644]
dali/public-api/render-tasks/render-task.h
dali/public-api/shader-effects/shader-effect.h

index 160dbd52007abc9a8ec74eceab903944d7b6e902..c5d0b0b25cc1dc70a38057b99ca57510d2d3305a 100644 (file)
@@ -254,51 +254,51 @@ public:
   {
     enum
     {
-      PARENT_ORIGIN = DEFAULT_ACTOR_PROPERTY_START_INDEX, ///< name "parent-origin",         type Vector3
-      PARENT_ORIGIN_X,                                    ///< name "parent-origin-x",       type Float
-      PARENT_ORIGIN_Y,                                    ///< name "parent-origin-y",       type Float
-      PARENT_ORIGIN_Z,                                    ///< name "parent-origin-z",       type Float
-      ANCHOR_POINT,                                       ///< name "anchor-point",          type Vector3
-      ANCHOR_POINT_X,                                     ///< name "anchor-point-x",        type Float
-      ANCHOR_POINT_Y,                                     ///< name "anchor-point-y",        type Float
-      ANCHOR_POINT_Z,                                     ///< name "anchor-point-z",        type Float
-      SIZE,                                               ///< name "size",                  type Vector3
-      SIZE_WIDTH,                                         ///< name "size-width",            type Float
-      SIZE_HEIGHT,                                        ///< name "size-height",           type Float
-      SIZE_DEPTH,                                         ///< name "size-depth",            type Float
-      POSITION,                                           ///< name "position",              type Vector3
-      POSITION_X,                                         ///< name "position-x",            type Float
-      POSITION_Y,                                         ///< name "position-y",            type Float
-      POSITION_Z,                                         ///< name "position-z",            type Float
-      WORLD_POSITION,                                     ///< name "world-position",        type Vector3  (read-only)
-      WORLD_POSITION_X,                                   ///< name "world-position-x",      type Float    (read-only)
-      WORLD_POSITION_Y,                                   ///< name "world-position-y",      type Float    (read-only)
-      WORLD_POSITION_Z,                                   ///< name "world-position-z",      type Float    (read-only)
-      ROTATION,                                           ///< name "rotation",              type Rotation
-      WORLD_ROTATION,                                     ///< name "world-rotation",        type Rotation (read-only)
-      SCALE,                                              ///< name "scale",                 type Vector3
-      SCALE_X,                                            ///< name "scale-x",               type Float
-      SCALE_Y,                                            ///< name "scale-y",               type Float
-      SCALE_Z,                                            ///< name "scale-z",               type Float
-      WORLD_SCALE,                                        ///< name "world-scale",           type Vector3  (read-only)
-      VISIBLE,                                            ///< name "visible",               type Boolean
-      COLOR,                                              ///< name "color",                 type Vector4
-      COLOR_RED,                                          ///< name "color-red",             type Float
-      COLOR_GREEN,                                        ///< name "color-green",           type Float
-      COLOR_BLUE,                                         ///< name "color-blue",            type Float
-      COLOR_ALPHA,                                        ///< name "color-alpha",           type Float
-      WORLD_COLOR,                                        ///< name "world-color",           type Vector4  (read-only)
-      WORLD_MATRIX,                                       ///< name "world-matrix",          type Matrix   (read-only)
-      NAME,                                               ///< name "name",                  type String
-      SENSITIVE,                                          ///< name "sensitive",             type Boolean
-      LEAVE_REQUIRED,                                     ///< name "leave-required",        type Boolean
-      INHERIT_ROTATION,                                   ///< name "inherit-rotation",      type Boolean
-      INHERIT_SCALE,                                      ///< name "inherit-scale",         type Boolean
-      COLOR_MODE,                                         ///< name "color-mode",            type String
-      POSITION_INHERITANCE,                               ///< name "position-inheritance",  type String
-      DRAW_MODE,                                          ///< name "draw-mode",             type String
-      SIZE_MODE,                                          ///< name "size-mode",             type String
-      SIZE_MODE_FACTOR,                                   ///< name "size-mode-factor",      type Vector3
+      PARENT_ORIGIN = DEFAULT_ACTOR_PROPERTY_START_INDEX, ///< name "parent-origin",         type VECTOR3
+      PARENT_ORIGIN_X,                                    ///< name "parent-origin-x",       type FLOAT
+      PARENT_ORIGIN_Y,                                    ///< name "parent-origin-y",       type FLOAT
+      PARENT_ORIGIN_Z,                                    ///< name "parent-origin-z",       type FLOAT
+      ANCHOR_POINT,                                       ///< name "anchor-point",          type VECTOR3
+      ANCHOR_POINT_X,                                     ///< name "anchor-point-x",        type FLOAT
+      ANCHOR_POINT_Y,                                     ///< name "anchor-point-y",        type FLOAT
+      ANCHOR_POINT_Z,                                     ///< name "anchor-point-z",        type FLOAT
+      SIZE,                                               ///< name "size",                  type VECTOR3
+      SIZE_WIDTH,                                         ///< name "size-width",            type FLOAT
+      SIZE_HEIGHT,                                        ///< name "size-height",           type FLOAT
+      SIZE_DEPTH,                                         ///< name "size-depth",            type FLOAT
+      POSITION,                                           ///< name "position",              type VECTOR3
+      POSITION_X,                                         ///< name "position-x",            type FLOAT
+      POSITION_Y,                                         ///< name "position-y",            type FLOAT
+      POSITION_Z,                                         ///< name "position-z",            type FLOAT
+      WORLD_POSITION,                                     ///< name "world-position",        type VECTOR3  (read-only)
+      WORLD_POSITION_X,                                   ///< name "world-position-x",      type FLOAT    (read-only)
+      WORLD_POSITION_Y,                                   ///< name "world-position-y",      type FLOAT    (read-only)
+      WORLD_POSITION_Z,                                   ///< name "world-position-z",      type FLOAT    (read-only)
+      ROTATION,                                           ///< name "rotation",              type ROTATION
+      WORLD_ROTATION,                                     ///< name "world-rotation",        type ROTATION (read-only)
+      SCALE,                                              ///< name "scale",                 type VECTOR3
+      SCALE_X,                                            ///< name "scale-x",               type FLOAT
+      SCALE_Y,                                            ///< name "scale-y",               type FLOAT
+      SCALE_Z,                                            ///< name "scale-z",               type FLOAT
+      WORLD_SCALE,                                        ///< name "world-scale",           type VECTOR3  (read-only)
+      VISIBLE,                                            ///< name "visible",               type BOOLEAN
+      COLOR,                                              ///< name "color",                 type VECTOR4
+      COLOR_RED,                                          ///< name "color-red",             type FLOAT
+      COLOR_GREEN,                                        ///< name "color-green",           type FLOAT
+      COLOR_BLUE,                                         ///< name "color-blue",            type FLOAT
+      COLOR_ALPHA,                                        ///< name "color-alpha",           type FLOAT
+      WORLD_COLOR,                                        ///< name "world-color",           type VECTOR4  (read-only)
+      WORLD_MATRIX,                                       ///< name "world-matrix",          type MATRIX   (read-only)
+      NAME,                                               ///< name "name",                  type STRING
+      SENSITIVE,                                          ///< name "sensitive",             type BOOLEAN
+      LEAVE_REQUIRED,                                     ///< name "leave-required",        type BOOLEAN
+      INHERIT_ROTATION,                                   ///< name "inherit-rotation",      type BOOLEAN
+      INHERIT_SCALE,                                      ///< name "inherit-scale",         type BOOLEAN
+      COLOR_MODE,                                         ///< name "color-mode",            type STRING
+      POSITION_INHERITANCE,                               ///< name "position-inheritance",  type STRING
+      DRAW_MODE,                                          ///< name "draw-mode",             type STRING
+      SIZE_MODE,                                          ///< name "size-mode",             type STRING
+      SIZE_MODE_FACTOR,                                   ///< name "size-mode-factor",      type VECTOR3
     };
   };
 
index efa1da163dbe63480262f9aaf81d2fdcc0c15c99..ec8a4fb874dd6b22b601e380b1bb770f76ca7f55 100644 (file)
@@ -78,20 +78,20 @@ public:
   {
     enum
     {
-      TYPE = DEFAULT_DERIVED_ACTOR_PROPERTY_START_INDEX, ///< name "type",                  type String
-      PROJECTION_MODE,                                   ///< name "projection-mode",       type String
-      FIELD_OF_VIEW,                                     ///< name "field-of-view",         type Float
-      ASPECT_RATIO,                                      ///< name "aspect-ratio",          type Float
-      NEAR_PLANE_DISTANCE,                               ///< name "near-plane-distance",   type Float
-      FAR_PLANE_DISTANCE,                                ///< name "far-plane-distance",    type Float
-      LEFT_PLANE_DISTANCE,                               ///< name "left-plane-distance",   type Float
-      RIGHT_PLANE_DISTANCE,                              ///< name "right-plane-distance",  type Float
-      TOP_PLANE_DISTANCE,                                ///< name "top-plane-distance",    type Float
-      BOTTOM_PLANE_DISTANCE,                             ///< name "bottom-plane-distance", type Float
-      TARGET_POSITION,                                   ///< name "target-position",       type Vector3
-      PROJECTION_MATRIX,                                 ///< name "projection-matrix",     type Matrix
-      VIEW_MATRIX,                                       ///< name "view-matrix",           type Matrix
-      INVERT_Y_AXIS,                                     ///< name "invert-y-axis",         type Boolean
+      TYPE = DEFAULT_DERIVED_ACTOR_PROPERTY_START_INDEX, ///< name "type",                  type STRING
+      PROJECTION_MODE,                                   ///< name "projection-mode",       type STRING
+      FIELD_OF_VIEW,                                     ///< name "field-of-view",         type FLOAT
+      ASPECT_RATIO,                                      ///< name "aspect-ratio",          type FLOAT
+      NEAR_PLANE_DISTANCE,                               ///< name "near-plane-distance",   type FLOAT
+      FAR_PLANE_DISTANCE,                                ///< name "far-plane-distance",    type FLOAT
+      LEFT_PLANE_DISTANCE,                               ///< name "left-plane-distance",   type FLOAT
+      RIGHT_PLANE_DISTANCE,                              ///< name "right-plane-distance",  type FLOAT
+      TOP_PLANE_DISTANCE,                                ///< name "top-plane-distance",    type FLOAT
+      BOTTOM_PLANE_DISTANCE,                             ///< name "bottom-plane-distance", type FLOAT
+      TARGET_POSITION,                                   ///< name "target-position",       type VECTOR3
+      PROJECTION_MATRIX,                                 ///< name "projection-matrix",     type MATRIX
+      VIEW_MATRIX,                                       ///< name "view-matrix",           type MATRIX
+      INVERT_Y_AXIS,                                     ///< name "invert-y-axis",         type BOOLEAN
     };
   };
 
index f5ae2daf8c0dd50846be81f1f22862af6420d9cb..5e699a46b860ca186c0105209ddad2031277963d 100644 (file)
@@ -70,10 +70,10 @@ public:
   {
     enum
     {
-      PIXEL_AREA = DEFAULT_DERIVED_ACTOR_PROPERTY_START_INDEX, ///< name "pixel-area",  type Rectangle
-      STYLE,                                                   ///< name "style",       type String
-      BORDER,                                                  ///< name "border",      type Vector4
-      IMAGE,                                                   ///< name "image",       type Map {"filename":"", "load-policy":...}
+      PIXEL_AREA = DEFAULT_DERIVED_ACTOR_PROPERTY_START_INDEX, ///< name "pixel-area",  type RECTANGLE
+      STYLE,                                                   ///< name "style",       type STRING
+      BORDER,                                                  ///< name "border",      type VECTOR4
+      IMAGE,                                                   ///< name "image",       type MAP {"filename":"", "load-policy":...}
     };
   };
 
index af9d87957ae72a65ee09acbe061ec481700e9d07..699fa1f170736f5148bf81552e1e5beaeafd9c0b 100644 (file)
@@ -73,8 +73,8 @@ public:
   {
     enum
     {
-      CLIPPING_ENABLE = DEFAULT_DERIVED_ACTOR_PROPERTY_START_INDEX, ///< name "clipping-enable",  type Boolean
-      CLIPPING_BOX,                                                 ///< name "clipping-box",     type Rectangle
+      CLIPPING_ENABLE = DEFAULT_DERIVED_ACTOR_PROPERTY_START_INDEX, ///< name "clipping-enable",  type BOOLEAN
+      CLIPPING_BOX,                                                 ///< name "clipping-box",     type RECTANGLE
     };
   };
 
index 3cea27aa1abeb3b3bbfd9206c70a59caa0ccd2ee..c9fe7fa5c214da131a4feabea3ea00d33e41af33 100644 (file)
@@ -68,28 +68,28 @@ public:
   {
     enum
     {
-      TEXT = DEFAULT_DERIVED_ACTOR_PROPERTY_START_INDEX, ///< name "text"                     type String
-      FONT,                                              ///< name "font"                     type String
-      FONT_STYLE,                                        ///< name "font-style"               type String
-      OUTLINE_ENABLE,                                    ///< name "outline-enable"           type Boolean
-      OUTLINE_COLOR,                                     ///< name "outline-color"            type Vector4
-      OUTLINE_THICKNESS_WIDTH,                           ///< name "outline-thickness-width"  type Vector2
-      SMOOTH_EDGE,                                       ///< name "smooth-edge"              type Float
-      GLOW_ENABLE,                                       ///< name "glow-enable"              type Boolean
-      GLOW_COLOR,                                        ///< name "glow-color"               type Vector4
-      GLOW_INTENSITY,                                    ///< name "glow-intensity"           type Float
-      SHADOW_ENABLE,                                     ///< name "shadow-enable"            type Boolean
-      SHADOW_COLOR,                                      ///< name "shadow-color"             type Vector4
-      SHADOW_OFFSET,                                     ///< name "shadow-offset"            type Vector2
-      ITALICS_ANGLE,                                     ///< name "italics-angle"            type Float
-      UNDERLINE,                                         ///< name "underline"                type Boolean
-      WEIGHT,                                            ///< name "weight"                   type Integer
-      FONT_DETECTION_AUTOMATIC,                          ///< name "font-detection-automatic" type Boolean
-      GRADIENT_COLOR,                                    ///< name "gradient-color"           type Vector4
-      GRADIENT_START_POINT,                              ///< name "gradient-start-point"     type Vector2
-      GRADIENT_END_POINT,                                ///< name "gradient-end-point"       type Vector2
-      SHADOW_SIZE,                                       ///< name "shadow-size"              type Float
-      TEXT_COLOR,                                        ///< name "text-color"               type Vector4
+      TEXT = DEFAULT_DERIVED_ACTOR_PROPERTY_START_INDEX, ///< name "text"                     type STRING
+      FONT,                                              ///< name "font"                     type STRING
+      FONT_STYLE,                                        ///< name "font-style"               type STRING
+      OUTLINE_ENABLE,                                    ///< name "outline-enable"           type BOOLEAN
+      OUTLINE_COLOR,                                     ///< name "outline-color"            type VECTOR4
+      OUTLINE_THICKNESS_WIDTH,                           ///< name "outline-thickness-width"  type VECTOR2
+      SMOOTH_EDGE,                                       ///< name "smooth-edge"              type FLOAT
+      GLOW_ENABLE,                                       ///< name "glow-enable"              type BOOLEAN
+      GLOW_COLOR,                                        ///< name "glow-color"               type VECTOR4
+      GLOW_INTENSITY,                                    ///< name "glow-intensity"           type FLOAT
+      SHADOW_ENABLE,                                     ///< name "shadow-enable"            type BOOLEAN
+      SHADOW_COLOR,                                      ///< name "shadow-color"             type VECTOR4
+      SHADOW_OFFSET,                                     ///< name "shadow-offset"            type VECTOR2
+      ITALICS_ANGLE,                                     ///< name "italics-angle"            type FLOAT
+      UNDERLINE,                                         ///< name "underline"                type BOOLEAN
+      WEIGHT,                                            ///< name "weight"                   type INTEGER
+      FONT_DETECTION_AUTOMATIC,                          ///< name "font-detection-automatic" type BOOLEAN
+      GRADIENT_COLOR,                                    ///< name "gradient-color"           type VECTOR4
+      GRADIENT_START_POINT,                              ///< name "gradient-start-point"     type VECTOR2
+      GRADIENT_END_POINT,                                ///< name "gradient-end-point"       type VECTOR2
+      SHADOW_SIZE,                                       ///< name "shadow-size"              type FLOAT
+      TEXT_COLOR,                                        ///< name "text-color"               type VECTOR4
     };
   };
 
index 81c743437b10cc8ee1523c48677460ce03aa09cd..0c26d56fde9e273342344570ecf9765cec1353fc 100644 (file)
@@ -52,7 +52,7 @@ public:
   {
     enum
     {
-      WEIGHT = DEFAULT_DERIVED_HANDLE_PROPERTY_START_INDEX, ///< name "weight", type Float
+      WEIGHT = DEFAULT_DERIVED_HANDLE_PROPERTY_START_INDEX, ///< name "weight", type FLOAT
     };
   };
 
index e5659e8908d9ddd818caddc9b80a58a617c9bc23..9107a5faa1ac56e3cc13133411906556264f2015 100644 (file)
@@ -46,8 +46,8 @@ public:
   {
     enum
     {
-      POINTS         = DEFAULT_DERIVED_HANDLE_PROPERTY_START_INDEX, ///< name "points",         type Vector3
-      CONTROL_POINTS,                                               ///< name "control-points", type Vector3
+      POINTS         = DEFAULT_DERIVED_HANDLE_PROPERTY_START_INDEX, ///< name "points",         type VECTOR3
+      CONTROL_POINTS,                                               ///< name "control-points", type VECTOR3
     };
   };
 
index 37711b16e8444716ad5583278cb147843d1386c9..11cceab1e185320e5096a3866afe4a6fb9e7d546 100644 (file)
@@ -68,13 +68,13 @@ public:
   {
     enum
     {
-      SCREEN_POSITION = DEFAULT_GESTURE_DETECTOR_PROPERTY_START_INDEX, ///< name "screen-position",     type Vector2
-      SCREEN_DISPLACEMENT,                                             ///< name "screen-displacement", type Vector2
-      SCREEN_VELOCITY,                                                 ///< name "screen-velocity",     type Vector2
-      LOCAL_POSITION,                                                  ///< name "local-position",      type Vector2
-      LOCAL_DISPLACEMENT,                                              ///< name "local-displacement",  type Vector2
-      LOCAL_VELOCITY,                                                  ///< name "local-velocity",      type Vector2
-      PANNING,                                                         ///< name "panning",             type Boolean
+      SCREEN_POSITION = DEFAULT_GESTURE_DETECTOR_PROPERTY_START_INDEX, ///< name "screen-position",     type VECTOR2
+      SCREEN_DISPLACEMENT,                                             ///< name "screen-displacement", type VECTOR2
+      SCREEN_VELOCITY,                                                 ///< name "screen-velocity",     type VECTOR2
+      LOCAL_POSITION,                                                  ///< name "local-position",      type VECTOR2
+      LOCAL_DISPLACEMENT,                                              ///< name "local-displacement",  type VECTOR2
+      LOCAL_VELOCITY,                                                  ///< name "local-velocity",      type VECTOR2
+      PANNING,                                                         ///< name "panning",             type BOOLEAN
     };
   };
 
index b68aa3a3dad48c94f9637f1861f5c307eade15f7..4346e5defbccf6aff0aed3ee0aafa9b6df66a595 100644 (file)
@@ -253,7 +253,8 @@ public_api_core_object_header_files = \
   $(public_api_src_dir)/object/property.h \
   $(public_api_src_dir)/object/ref-object.h \
   $(public_api_src_dir)/object/type-info.h \
-  $(public_api_src_dir)/object/type-registry.h
+  $(public_api_src_dir)/object/type-registry.h \
+  $(public_api_src_dir)/object/type-registry-helper.h
 
 public_api_core_render_tasks_header_files = \
   $(public_api_src_dir)/render-tasks/render-task.h \
index 400f0c1a3243f7f505644919c9c492a96e35c983..16ce066871404989217e56350675ad10a710db97 100644 (file)
@@ -58,9 +58,9 @@ public:
   {
     enum
     {
-      POSITION      = DEFAULT_DERIVED_HANDLE_PROPERTY_START_INDEX, ///< name prefix "position-",        type Vector3
-      COLOR,                                                       ///< name prefix "color-",           type Vector4
-      TEXTURE_COORDS,                                              ///< name prefix "texture-coords-",  type Vector2
+      POSITION      = DEFAULT_DERIVED_HANDLE_PROPERTY_START_INDEX, ///< name prefix "position-",        type VECTOR3
+      COLOR,                                                       ///< name prefix "color-",           type VECTOR4
+      TEXTURE_COORDS,                                              ///< name prefix "texture-coords-",  type VECTOR2
     };
   };
 
diff --git a/dali/public-api/object/type-registry-helper.h b/dali/public-api/object/type-registry-helper.h
new file mode 100644 (file)
index 0000000..15fc090
--- /dev/null
@@ -0,0 +1,78 @@
+#ifndef __DALI_TYPE_REGISTRY_HELPER_H__
+#define __DALI_TYPE_REGISTRY_HELPER_H__
+
+/*
+ * Copyright (c) 2014 Samsung Electronics Co., Ltd.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ *
+ */
+
+// INTERNAL INCLUDES
+#include <dali/public-api/common/compile-time-assert.h>
+#include <dali/public-api/object/type-registry.h>
+
+namespace Dali
+{
+
+namespace Internal
+{
+
+/**
+ * @brief These macros are used to use the type-registry to register properties and signals.
+ * This forces registration to be done in a standard way across actors and controls and facilitates future compile-time checks to be added.
+ *
+ * Note: Currently a compile time check is done for the order of the properties. The order is not critical to registration, but helps maintain the ordering between the header and implementations to avoid properties being added out of place.
+ *
+ * Note: The signal macro also generates string const chars.
+ */
+#define DALI_TOKEN_PASTE_EXPAND( x, y ) x ## y
+#define DALI_TOKEN_PASTE( x, y ) DALI_TOKEN_PASTE_EXPAND(x, y)
+
+#define DALI_PROPERTY_REGISTRATION_INTERNAL( count, typeRegistrationObject, objectType, text, valueType, enumIndex ) \
+  PropertyRegistration DALI_TOKEN_PASTE( property, count ) ( typeRegistrationObject, text, Toolkit::objectType::Property::enumIndex, Property::valueType, &objectType::SetProperty, &objectType::GetProperty ); \
+  DALI_COMPILE_TIME_ASSERT( ( Toolkit::objectType::Property::enumIndex - Toolkit::objectType::PROPERTY_START_INDEX ) == count );
+
+#define DALI_SIGNAL_REGISTRATION_INTERNAL( count, typeRegistrationObject, objectType, text, textVariable ) \
+  const char* const textVariable = text; \
+  SignalConnectorType DALI_TOKEN_PASTE( signalConnector, count ) ( typeRegistrationObject, text, &Toolkit::Internal::objectType::DoConnectSignal );
+
+#define DALI_ACTION_REGISTRATION_INTERNAL( count, typeRegistrationObject, objectType, text, textVariable ) \
+  const char* const textVariable = text; \
+  TypeAction DALI_TOKEN_PASTE( signalConnector, count ) ( typeRegistrationObject, text, &Toolkit::Internal::objectType::DoAction );
+
+// For use within implementations:
+
+#define DALI_TYPE_REGISTRATION_BEGIN( thisType, baseType, createFunction ) \
+  TypeRegistration typeRegistration( typeid( thisType ), typeid( baseType ), createFunction );
+
+#define DALI_TYPE_REGISTRATION_BEGIN_CREATE( thisType, baseType, createFunction, createAtStartup ) \
+  TypeRegistration typeRegistration( typeid( thisType ), typeid( baseType ), createFunction, createAtStartup );
+
+#define DALI_PROPERTY_REGISTRATION( objectType, text, valueType, enumIndex ) \
+  DALI_PROPERTY_REGISTRATION_INTERNAL( __COUNTER__, typeRegistration, objectType, text, valueType, enumIndex )
+
+#define DALI_SIGNAL_REGISTRATION( objectType, text, textVariable ) \
+  DALI_SIGNAL_REGISTRATION_INTERNAL( __COUNTER__, typeRegistration, objectType, text, textVariable )
+
+#define DALI_ACTION_REGISTRATION( objectType, text, textVariable ) \
+  DALI_ACTION_REGISTRATION_INTERNAL( __COUNTER__, typeRegistration, objectType, text, textVariable )
+
+#define DALI_TYPE_REGISTRATION_END( ) // Empty for now, can be used to perform checks.
+
+
+} // namespace Internal
+
+} // namespace Dali
+
+#endif // __DALI_TYPE_REGISTRY_HELPER_H__
index aab9c52c42fc60323f24183ce54ae89ff282591f..4ce7e2a47e655f36677c6876871f446488054d96 100644 (file)
@@ -86,9 +86,9 @@ public:
   {
     enum
     {
-      VIEWPORT_POSITION = DEFAULT_DERIVED_HANDLE_PROPERTY_START_INDEX, ///< name "viewport-position", type Vector2
-      VIEWPORT_SIZE,                                                   ///< name "viewport-size",     type Vector2
-      CLEAR_COLOR,                                                     ///< name "clear-color",       type Vector4
+      VIEWPORT_POSITION = DEFAULT_DERIVED_HANDLE_PROPERTY_START_INDEX, ///< name "viewport-position", type VECTOR2
+      VIEWPORT_SIZE,                                                   ///< name "viewport-size",     type VECTOR2
+      CLEAR_COLOR,                                                     ///< name "clear-color",       type VECTOR4
     };
   };
 
index ff03e295b6a1ebc7cf417b313fb498b04136d3e4..61f967ebc703867b6270772ccb2f919d758a4508 100644 (file)
@@ -173,7 +173,7 @@ public:
       GRID_DENSITY = DEFAULT_ACTOR_PROPERTY_START_INDEX, ///< name "grid-density",   type FLOAT
       IMAGE,                                             ///< name "image",          type MAP  {"filename":"", "load-policy":...}
       PROGRAM,                                           ///< name "program",        type MAP  {"vertex-prefix":"","fragment-prefix":"","vertex":"","fragment":""}
-      GEOMETRY_HINTS                                     ///< name "geometry-hints", type INT  (bitfield) values from enum GeometryHints
+      GEOMETRY_HINTS                                     ///< name "geometry-hints", type INTEGER (bitfield) values from enum GeometryHints
     };
   };