[dali_2.3.24] Merge branch 'devel/master'
[platform/core/uifw/dali-toolkit.git] / dali-toolkit / public-api / controls / buttons / radio-button.h
index 18a999a..1ab4c71 100644 (file)
@@ -2,7 +2,7 @@
 #define DALI_TOOLKIT_RADIO_BUTTON_H
 
 /*
- * Copyright (c) 2019 Samsung Electronics Co., Ltd.
+ * Copyright (c) 2029 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.
 
 namespace Dali
 {
-
 namespace Toolkit
 {
-
 // Forward declarations
 
 namespace Internal DALI_INTERNAL
@@ -34,7 +32,7 @@ namespace Internal DALI_INTERNAL
 // Forward declarations
 
 class RadioButton;
-}
+} // namespace DALI_INTERNAL
 /**
  * @addtogroup dali_toolkit_controls_buttons
  * @{
@@ -71,22 +69,22 @@ class RadioButton;
  * RadioButton button1 = RadioButton::New();
  * button1.SetProperty( Button::Property::LABEL, "button1" );
  * button1.SetBackgroundColor( Color::WHITE );
- * button1.SetPosition( 0, -40 );
+ * button1.SetProperty( Actor::Property::POSITION, Vector2( 0, -40 ) );
  * radioGroup.Add( button1 );
  *
  * // Make more RadioButtons and add them to their parent
  * RadioButton button2 = RadioButton::New();
  * button2.SetProperty( Toolkit::Button::Property::LABEL, "button2" );
  * button2.SetBackgroundColor( Color::WHITE );
- * button2.SetPosition( 0, 40 );
+ * button2.SetProperty( Actor::Property::POSITION, Vector2( 0, 40 ) );
  * radioGroup.Add( button2 );
  *
  * @endcode
  * @SINCE_1_0.0
  */
-class DALI_TOOLKIT_API RadioButton: public Button
+class DALI_TOOLKIT_API RadioButton : public Button
 {
- public:
+public:
   /**
    * @brief Creates an uninitialized RadioButton; this can be initialized with RadioButton::New().
    *
@@ -100,7 +98,15 @@ class DALI_TOOLKIT_API RadioButton: public Button
    * @SINCE_1_0.0
    * @param[in] radioButton Handle to an object
    */
-  RadioButton( const RadioButton& radioButton );
+  RadioButton(const RadioButton& radioButton);
+
+  /**
+   * @brief Move constructor
+   * @SINCE_1_9.23
+   *
+   * @param[in] rhs A reference to the moved handle
+   */
+  RadioButton(RadioButton&& rhs) noexcept;
 
   /**
    * @brief Assignment operator.
@@ -108,7 +114,16 @@ class DALI_TOOLKIT_API RadioButton: public Button
    * @param[in] radioButton Handle to an object
    * @return A reference to this
    */
-  RadioButton& operator=( const RadioButton& radioButton );
+  RadioButton& operator=(const RadioButton& radioButton);
+
+  /**
+   * @brief Move assignment
+   * @SINCE_1_9.23
+   *
+   * @param[in] rhs A reference to the moved handle
+   * @return A reference to this
+   */
+  RadioButton& operator=(RadioButton&& rhs) noexcept;
 
   /**
    * @brief Destructor.
@@ -133,7 +148,7 @@ class DALI_TOOLKIT_API RadioButton: public Button
    * @param[in] label The button label
    * @return A handle to a newly allocated Dali resource
    */
-  static RadioButton New( const std::string& label );
+  static RadioButton New(const std::string& label);
 
   /**
    * @brief Downcasts a handle to RadioButton handle.
@@ -145,10 +160,9 @@ class DALI_TOOLKIT_API RadioButton: public Button
    * @param[in] handle Handle to an object
    * @return A handle to a RadioButton or an uninitialized handle
    */
-  static RadioButton DownCast( BaseHandle handle );
-
- public: // Not intended for application developers
+  static RadioButton DownCast(BaseHandle handle);
 
+public: // Not intended for application developers
   /// @cond internal
   /**
    * @brief Creates a handle using the Toolkit::Internal implementation.
@@ -156,7 +170,7 @@ class DALI_TOOLKIT_API RadioButton: public Button
    * @SINCE_1_0.0
    * @param[in] implementation The Control implementation
    */
-  DALI_INTERNAL RadioButton( Internal::RadioButton& implementation );
+  DALI_INTERNAL RadioButton(Internal::RadioButton& implementation);
 
   /**
    * @brief Allows the creation of this Control from an Internal::CustomActor pointer.
@@ -164,7 +178,7 @@ class DALI_TOOLKIT_API RadioButton: public Button
    * @SINCE_1_0.0
    * @param[in] internal A pointer to the internal CustomActor
    */
-  DALI_INTERNAL RadioButton( Dali::Internal::CustomActor* internal );
+  DALI_INTERNAL RadioButton(Dali::Internal::CustomActor* internal);
   /// @endcond
 };