X-Git-Url: http://review.tizen.org/git/?p=platform%2Fcore%2Fuifw%2Fdali-toolkit.git;a=blobdiff_plain;f=dali-toolkit%2Fpublic-api%2Fcontrols%2Fbuttons%2Fbutton.cpp;h=02adab4c97d1bf730e3f646c3ebb68362da050a3;hp=ab953bf928dc8c85a6d1ad242ba9ba307280c1d7;hb=4593cc619ab0739fc8586c0c752209c555b0c8e3;hpb=c8a0c614eaa58cb6c9aa39a8e44cf027d4fe71eb diff --git a/dali-toolkit/public-api/controls/buttons/button.cpp b/dali-toolkit/public-api/controls/buttons/button.cpp index ab953bf..02adab4 100644 --- a/dali-toolkit/public-api/controls/buttons/button.cpp +++ b/dali-toolkit/public-api/controls/buttons/button.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014 Samsung Electronics Co., Ltd. + * Copyright (c) 2020 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. @@ -16,12 +16,16 @@ */ // CLASS HEADER - #include -// INTERNAL INCLUDES +// EXTERNAL INCLUDES +#include +#include +// INTERNAL INCLUDES #include +#include +#include namespace Dali { @@ -32,19 +36,13 @@ namespace Toolkit Button::Button() {} -Button::Button( const Button& button ) -: Control( button ) -{ -} +Button::Button( const Button& button ) = default; -Button& Button::operator=( const Button& button ) -{ - if( &button != this ) - { - Control::operator=( button ); - } - return *this; -} +Button::Button( Button&& rhs ) = default; + +Button& Button::operator=( const Button& button ) = default; + +Button& Button::operator=( Button&& rhs ) = default; Button::~Button() { @@ -55,91 +53,6 @@ Button Button::DownCast( BaseHandle handle ) return Control::DownCast(handle); } -void Button::SetDisabled( bool disabled ) -{ - Dali::Toolkit::GetImplementation( *this ).SetDisabled( disabled ); -} - -bool Button::IsDisabled() const -{ - return Dali::Toolkit::GetImplementation( *this ).IsDisabled(); -} - -void Button::SetAutoRepeating( bool autoRepeating ) -{ - Dali::Toolkit::GetImplementation( *this ).SetAutoRepeating( autoRepeating ); -} - -bool Button::IsAutoRepeating() const -{ - return Dali::Toolkit::GetImplementation( *this ).IsAutoRepeating(); -} - -void Button::SetInitialAutoRepeatingDelay( float initialAutoRepeatingDelay ) -{ - Dali::Toolkit::GetImplementation( *this ).SetInitialAutoRepeatingDelay( initialAutoRepeatingDelay ); -} - -float Button::GetInitialAutoRepeatingDelay() const -{ - return Dali::Toolkit::GetImplementation( *this ).GetInitialAutoRepeatingDelay(); -} - -void Button::SetNextAutoRepeatingDelay( float nextAutoRepeatingDelay ) -{ - Dali::Toolkit::GetImplementation( *this ).SetNextAutoRepeatingDelay( nextAutoRepeatingDelay ); -} - -float Button::GetNextAutoRepeatingDelay() const -{ - return Dali::Toolkit::GetImplementation( *this ).GetNextAutoRepeatingDelay(); -} - -void Button::SetTogglableButton( bool togglable ) -{ - Dali::Toolkit::GetImplementation( *this ).SetTogglableButton( togglable ); -} - -bool Button::IsTogglableButton() const -{ - return Dali::Toolkit::GetImplementation( *this ).IsTogglableButton(); -} - -void Button::SetSelected( bool selected ) -{ - Dali::Toolkit::GetImplementation( *this ).SetSelected( selected ); -} - -bool Button::IsSelected() const -{ - return Dali::Toolkit::GetImplementation( *this ).IsSelected(); -} - -void Button::SetAnimationTime( float animationTime ) -{ - Dali::Toolkit::GetImplementation( *this ).SetAnimationTime( animationTime ); -} - -float Button::GetAnimationTime() const -{ - return Dali::Toolkit::GetImplementation( *this ).GetAnimationTime(); -} - -void Button::SetLabel( const std::string& label ) -{ - Dali::Toolkit::GetImplementation( *this ).SetLabel( label ); -} - -void Button::SetLabel( Actor label ) -{ - Dali::Toolkit::GetImplementation( *this ).SetLabel( label ); -} - -Actor Button::GetLabel() const -{ - return Dali::Toolkit::GetImplementation( *this ).GetLabel(); -} - Button::ButtonSignalType& Button::PressedSignal() { return Dali::Toolkit::GetImplementation( *this ).PressedSignal();