X-Git-Url: http://review.tizen.org/git/?p=platform%2Fcore%2Fuifw%2Fdali-toolkit.git;a=blobdiff_plain;f=dali-toolkit%2Finternal%2Ftext%2Ftext-controller.h;h=324038444fcf93ef62d6740de0ae5befa9fabb9f;hp=9302cf50f5d32f7bf38239fa3b91d68549abf5d8;hb=00758f1301dd0bfbf6dc87659a6db9d0ba2c6816;hpb=cab6cfc0b656124cf8b51c7e484b9e2682e6bd1f diff --git a/dali-toolkit/internal/text/text-controller.h b/dali-toolkit/internal/text/text-controller.h index 9302cf5..3240384 100644 --- a/dali-toolkit/internal/text/text-controller.h +++ b/dali-toolkit/internal/text/text-controller.h @@ -35,11 +35,7 @@ #include #include -namespace Dali -{ -namespace Toolkit -{ -namespace Text +namespace Dali::Toolkit::Text { class Controller; class ControlInterface; @@ -170,7 +166,10 @@ public: // Constructor. * * @return A pointer to a new Controller. */ - static ControllerPtr New(); + static ControllerPtr New() + { + return ControllerPtr(new Controller()); + } /** * @brief Create a new instance of a Controller. @@ -179,7 +178,10 @@ public: // Constructor. * * @return A pointer to a new Controller. */ - static ControllerPtr New(ControlInterface* controlInterface); + static ControllerPtr New(ControlInterface* controlInterface) + { + return ControllerPtr(new Controller(controlInterface)); + } /** * @brief Create a new instance of a Controller. @@ -194,7 +196,13 @@ public: // Constructor. static ControllerPtr New(ControlInterface* controlInterface, EditableControlInterface* editableControlInterface, SelectableControlInterface* selectableControlInterface, - AnchorControlInterface* anchorControlInterface); + AnchorControlInterface* anchorControlInterface) + { + return ControllerPtr(new Controller(controlInterface, + editableControlInterface, + selectableControlInterface, + anchorControlInterface)); + } public: // Configure the text controller. /** @@ -1897,12 +1905,18 @@ private: // Private contructors & copy operator. /** * @brief Private constructor. */ - Controller(); + Controller() + : Controller(nullptr, nullptr, nullptr, nullptr) + { + } /** * @brief Private constructor. */ - Controller(ControlInterface* controlInterface); + Controller(ControlInterface* controlInterface) + : Controller(controlInterface, nullptr, nullptr, nullptr) + { + } /** * @brief Private constructor. @@ -1912,11 +1926,8 @@ private: // Private contructors & copy operator. SelectableControlInterface* selectableControlInterface, AnchorControlInterface* anchorControlInterface); - // Undefined - Controller(const Controller& handle); - - // Undefined - Controller& operator=(const Controller& handle); + Controller(const Controller& handle) = delete; + Controller& operator=(const Controller& handle) = delete; protected: // Destructor. /** @@ -1937,10 +1948,6 @@ private: Impl* mImpl; }; -} // namespace Text - -} // namespace Toolkit - -} // namespace Dali +} // namespace Dali::Toolkit::Text #endif // DALI_TOOLKIT_TEXT_CONTROLLER_H