X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=dali-toolkit%2Fpublic-api%2Fcontrols%2Fbuttons%2Fpush-button.cpp;h=22dba2d54676cfa25160d50ae09192197eed6804;hb=9601caa4c6862e87f072a6f0cba8a0a19036e55d;hp=d3f21d74039bf98e2e26a2bf8d72e929e67fa19c;hpb=f60d2ee843df1c81ea988c4a986e9168c905fcc9;p=platform%2Fcore%2Fuifw%2Fdali-toolkit.git diff --git a/dali-toolkit/public-api/controls/buttons/push-button.cpp b/dali-toolkit/public-api/controls/buttons/push-button.cpp index d3f21d7..22dba2d 100644 --- a/dali-toolkit/public-api/controls/buttons/push-button.cpp +++ b/dali-toolkit/public-api/controls/buttons/push-button.cpp @@ -16,13 +16,15 @@ */ // CLASS HEADER - #include -// INTERNAL INCLUDES +// EXTERNAL INCLUDES +#include +#include + +// INTERNAL INCLUDES #include -#include namespace Dali { @@ -74,64 +76,55 @@ PushButton PushButton::DownCast( BaseHandle handle ) return Control::DownCast(handle); } +// Deprecated API + void PushButton::SetButtonImage( Actor image ) { - Dali::Toolkit::GetImplementation( *this ).SetButtonImage( image ); -} + DALI_LOG_WARNING_NOFN("DEPRECATION WARNING: SetButtonImage() is deprecated and will be removed from next release. Use Button.SetProperty UNSELECTED_STATE_IMAGE or Styling file instead.\n" ); -Actor PushButton::GetButtonImage() const -{ - return Dali::Toolkit::GetImplementation( *this ).GetButtonImage(); + Dali::Toolkit::GetImplementation( *this ).SetButtonImage( image ); } void PushButton::SetBackgroundImage( Actor image ) { - Dali::Toolkit::GetImplementation( *this ).SetBackgroundImage( image ); -} + DALI_LOG_WARNING_NOFN("DEPRECATION WARNING: SetBackgroundImage() is deprecated and will be removed from next release.\n" ); -Actor PushButton::GetBackgroundImage() const -{ - return Dali::Toolkit::GetImplementation( *this ).GetBackgroundImage(); + Dali::Toolkit::GetImplementation( *this ).SetBackgroundImage( image ); } void PushButton::SetSelectedImage( Actor image ) { - Dali::Toolkit::GetImplementation( *this ).SetSelectedImage( image ); -} + DALI_LOG_WARNING_NOFN("DEPRECATION WARNING: SetSelectedImage() is deprecated and will be removed from next release. Use Button.SetProperty SELECTED_STATE_IMAGE or Styling file instead.\n" ); -Actor PushButton::GetSelectedImage() const -{ - return Dali::Toolkit::GetImplementation( *this ).GetSelectedImage(); + Dali::Toolkit::GetImplementation( *this ).SetSelectedImage( image ); } void PushButton::SetSelectedBackgroundImage( Actor image ) { - Dali::Toolkit::GetImplementation( *this ).SetSelectedBackgroundImage( image ); -} + DALI_LOG_WARNING_NOFN("DEPRECATION WARNING: SetSelectedBackgroundImage() is deprecated and will be removed from next release.\n" ); -Actor PushButton::GetSelectedBackgroundImage() const -{ - return Dali::Toolkit::GetImplementation( *this ).GetSelectedBackgroundImage(); + Dali::Toolkit::GetImplementation( *this ).SetSelectedBackgroundImage( image ); } void PushButton::SetDisabledBackgroundImage( Actor image ) { - Dali::Toolkit::GetImplementation( *this ).SetDisabledBackgroundImage( image ); -} + DALI_LOG_WARNING_NOFN("DEPRECATION WARNING: SetDisabledBackgroundImage() is deprecated and will be removed from next release.\n" ); -Actor PushButton::GetDisabledBackgroundImage() const -{ - return Dali::Toolkit::GetImplementation( *this ).GetDisabledBackgroundImage(); + Dali::Toolkit::GetImplementation( *this ).SetDisabledBackgroundImage( image ); } void PushButton::SetDisabledImage( Actor image ) { + DALI_LOG_WARNING_NOFN("DEPRECATION WARNING: SetDisabledImage() is deprecated and will be removed from next release. Use Button.SetProperty DISABLED_STATE_IMAGE or Styling file instead.\n" ); + Dali::Toolkit::GetImplementation( *this ).SetDisabledImage( image ); } -Actor PushButton::GetDisabledImage() const +void PushButton::SetDisabledSelectedImage( Actor image ) { - return Dali::Toolkit::GetImplementation( *this ).GetDisabledImage(); + DALI_LOG_WARNING_NOFN("DEPRECATION WARNING: SetDisabledSelectedImage() is deprecated and will be removed from next release.\n" ); + + Dali::Toolkit::GetImplementation( *this ).SetDisabledSelectedImage( image ); } } // namespace Toolkit