Add descriptions and example codes 50/82150/5
authorSeoyeon Kim <seoyeon2.kim@samsung.com>
Mon, 1 Aug 2016 07:09:34 +0000 (16:09 +0900)
committerSeoyeon Kim <seoyeon2.kim@samsung.com>
Tue, 16 Aug 2016 02:46:48 +0000 (11:46 +0900)
Change-Id: Ic36766645c41ca1831bfd0cfa817ca54df8957f3
Signed-off-by: Seoyeon Kim <seoyeon2.kim@samsung.com>
dali-toolkit/public-api/controls/buttons/check-box-button.h
dali-toolkit/public-api/controls/buttons/push-button.h
doc/dali-toolkit-doc.h

index 91f0157..ca5c288 100644 (file)
@@ -52,6 +52,30 @@ class CheckBoxButton;
  *
  * When the button is disabled, \e background image and \e selected image are replaced by \e disabled images.
  *
+ * Usage example: -
+ *
+ * @code
+ * // in Creating a DALi Application
+ * void HelloWorldExample::Create( Application& application )
+ * {
+ *   CheckBoxButton button = CheckBoxButton::New();
+ *   button.SetParentOrigin( ParentOrigin::CENTER );
+ *   button.SetLabelText( "Check" );
+ *   button.SetSize( 200, 40 );
+ *   button.SetBackgroundColor( Color::WHITE );
+ *   Stage::GetCurrent().Add( button );
+ *
+ *   // Connect to a button signal emitted by the button
+ *   button.StateChangedSignal().Connect( this, &HelloWorldExample::OnButtonStateChanged );
+ * }
+ *
+ * bool HelloWorldExample::OnButtonStateChanged( Button button )
+ * {
+ *   // Do something when the button state is changed
+ *   // You can get the state using button.IsSelected() call
+ *   return true;
+ * }
+ * @endcode
  * @SINCE_1_0.0
  */
 class DALI_IMPORT_API CheckBoxButton : public Button
index 4beab96..603601d 100644 (file)
@@ -46,6 +46,42 @@ class PushButton;
  * By default a PushButton emits a Button::PressedSignal() signal when the button is pressed, a Button::ClickedSignal() signal when it's clicked
  * and a Button::ReleasedSignal() signal when it's released or having pressed it, the touch point leaves the boundary of the button.
  *
+ * Usage example: -
+ *
+ * @code
+ * // in Creating a DALi Application
+ * void HelloWorldExample::Create( Application& application )
+ * {
+ *   PushButton button = PushButton::New();
+ *   button.SetParentOrigin( ParentOrigin::CENTER );
+ *   button.SetLabelText( "Press" );
+ *   Stage::GetCurrent().Add( button );
+ *
+ *   // Connect to button signals emitted by the button
+ *   button.ClickedSignal().Connect( this, &HelloWorldExample::OnButtonClicked );
+ *   button.PressedSignal().Connect( this, &HelloWorldExample::OnButtonPressed );
+ *   button.ReleasedSignal().Connect( this, &HelloWorldExample::OnButtonReleased );
+ * }
+ *
+ * bool HelloWorldExample::OnButtonClicked( Button button )
+ * {
+ *   // Do something when the button is clicked
+ *   return true;
+ * }
+ *
+ * bool HelloWorldExample::OnButtonPressed( Button button )
+ * {
+ *   // Do something when the button is pressed
+ *   return true;
+ * }
+ *
+ * bool HelloWorldExample::OnButtonReleased( Button button )
+ * {
+ *   // Do something when the button is released
+ *   return true;
+ * }
+ * @endcode
+ *
  * See Button for more detail on signals and modifying appearance via properties.
  * @SINCE_1_0.0
  */
index 41cf322..b2bd746 100644 (file)
  * </tr>
  * <tr>
  *    <td style="padding-left:1em">@ref dali_toolkit_controls_scroll_bar</td>
- *    <td>ScrollBar control.</td>
+ *    <td>ScrollBar is a component that can be linked to the scrollable objects.</td>
  * </tr>
  * <tr>
  *    <td style="padding-left:1em">@ref dali_toolkit_controls_scrollable</td>
- *    <td>Scrollable container controls.</td>
+ *    <td>Scrollable contains scrolled controls.</td>
  * </tr>
  * <tr>
  *    <td style="padding-left:2em">@ref dali_toolkit_controls_item_view</td>
  *     @brief ImageView is a control displying an image.
 
  *     @defgroup dali_toolkit_controls_scroll_bar Scroll Bar
- *     @brief ScrollBar control.
+ *     @brief ScrollBar is a component that can be linked to the scrollable objects.
 
  *     @defgroup dali_toolkit_controls_scrollable Scrollable
- *     @brief Scrollable container controls.
+ *     @brief Scrollable contains scrolled controls.
 
  *     @{
  *       @defgroup dali_toolkit_controls_item_view Item View