Ensure cached values of properties animated using AnimateTo are updated
[platform/core/uifw/dali-core.git] / dali / internal / event / common / object-impl.h
index d378674..035e7ee 100644 (file)
@@ -41,6 +41,7 @@ class PropertyNotification;
 
 namespace Internal
 {
+class Animation;
 class ConstraintBase;
 class EventThreadServices;
 class Handle;
@@ -239,6 +240,14 @@ public:
    */
   virtual void RemovePropertyNotifications();
 
+  /**
+   * Notifies that a property is being animated.
+   * @param[in] animation The animation animating the property.
+   * @param[in] index The index of the property.
+   * @param[in] value The value of the property after the animation.
+   */
+  void NotifyPropertyAnimation( Animation& animation, Property::Index index, const Property::Value& value );
+
   /******************************** Uniform Mappings ********************************/
 
   /**
@@ -479,6 +488,15 @@ private: // Default property extensions for derived classes
   virtual Property::Value GetDefaultPropertyCurrentValue( Property::Index index ) const = 0;
 
   /**
+   * Notifies that a default property is being animated so the deriving class should update the cached value.
+   * @param[in] animation The animation animating the property.
+   * @param[in] index The index of the property.
+   * @param[in] value The value of the property after the animation.
+   */
+  virtual void OnNotifyDefaultPropertyAnimation( Animation& animation, Property::Index index, const Property::Value& value )
+  { }
+
+  /**
    * @todo this is virtual so that for now actor can override it,
    * it needs to be removed and only have GetSceneObject but that requires changing actor and constraint logic
    * Retrieve the scene-graph object added by this object.