Merge "TextView - Uses new TextActor's constructor." into tizen
[platform/core/uifw/dali-toolkit.git] / capi / dali-toolkit / public-api / controls / scrollable / scroll-connector.h
index c8ac206..1e64e7e 100644 (file)
@@ -70,6 +70,9 @@ public:
   static const char* const DOMAIN_CHANGED_SIGNAL_NAME;    ///< "domain-changed" signal name
   typedef SignalV2< void ( float min, float max, float size ) > DomainChangedSignalType;
 
+  static const char* const SCROLL_POSITION_CHANGED_SIGNAL_NAME;    ///< "scroll-position-changed" signal name
+  typedef SignalV2< void ( float position ) > ScrollPositionChangedSignalType;
+
   /**
    * Create a ScrollConnector.
    * @return A handle to a newly allocated ScrollConnector.
@@ -93,18 +96,20 @@ public:
   using Dali::BaseHandle::operator=;
 
   /**
-   * Virtual destructor.
+   * @brief Destructor
+   *
+   * This is non-virtual since derived Handle types must not contain data or virtual methods.
    */
-  virtual ~ScrollConnector();
+  ~ScrollConnector();
 
   /**
-   * Downcast a BaseHandle to ScrollConnector handle.
+   * @brief Downcast a BaseHandle to ScrollConnector handle.
    * @return A handle to a ScrollConnector or an empty handle.
    */
   static ScrollConnector DownCast( BaseHandle handle );
 
   /**
-   * Set the scroll domain, corresponding to the start & end position, and size of the scrollable content in actor coordinates.
+   * @brief Set the scroll domain, corresponding to the start & end position, and size of the scrollable content in actor coordinates.
    * @param[in] min The minimum scroll position limit.
    * @param[in] max The maximum scroll position limit.
    * @param[in] length The length of the scrollable content in actor coordinates.
@@ -112,30 +117,50 @@ public:
   void SetScrollDomain( float min, float max, float length );
 
   /**
-   * Retrieve the min limit.
+   * @brief Retrieve the min limit.
    * @return The minimum value.
    */
   float GetMinLimit() const;
 
   /**
-   * Retrieve the max limit.
+   * @brief Retrieve the max limit.
    * @return The maximum value.
    */
   float GetMaxLimit() const;
 
   /**
-   * Retrieve the length of the scrollable content in actor coordinates.
+   * @brief Retrieve the length of the scrollable content in actor coordinates.
    * @return The length of the scrollable content.
    */
   float GetContentLength() const;
 
   /**
-   * Signal emitted after the SetScrollDomain() method has been called.
+   * @brief Set the scroll position.
+   *
+   * This will set the "scroll-position" property and emit the ScrollPositionChanged signal.
+   *
+   * @param[in] position The scroll position.
+   */
+  void SetScrollPosition( float position );
+
+  /**
+   * @brief Retrieve the scroll position.
+   * @return The scroll position.
+   */
+  float GetScrollPosition() const;
+
+  /**
+   * @brief Signal emitted after the SetScrollPosition() method has been called.
+   */
+  ScrollConnector::ScrollPositionChangedSignalType& ScrollPositionChangedSignal();
+
+  /**
+   * @brief Signal emitted after the SetScrollDomain() method has been called.
    */
   ScrollConnector::DomainChangedSignalType& DomainChangedSignal();
 
   /**
-   * Retrieve the object which provides the "scroll-position" property.
+   * @brief Retrieve the object which provides the "scroll-position" property.
    * @return The scroll-position object.
    */
   Constrainable GetScrollPositionObject() const;