From e1c67e5c294862493a3ac0fd1dd0f442e8bf0af8 Mon Sep 17 00:00:00 2001 From: suhyung Eom Date: Thu, 1 Dec 2016 18:22:39 +0900 Subject: [PATCH] Apply deprecate macro and LOG Signed-off-by: suhyung Eom Change-Id: I9d7761a315d757ea5e9c50a553593cc2fb818035 --- .../public-api/controls/buttons/button.cpp | 61 +++++++++++++++++++++- dali-toolkit/public-api/controls/buttons/button.h | 58 ++++++++++---------- .../public-api/controls/buttons/push-button.cpp | 19 ++++++- .../public-api/controls/buttons/push-button.h | 14 ++--- dali-toolkit/public-api/controls/control-impl.cpp | 3 +- dali-toolkit/public-api/controls/control-impl.h | 4 +- dali-toolkit/public-api/controls/control.cpp | 7 +++ dali-toolkit/public-api/controls/control.h | 4 +- .../public-api/controls/image-view/image-view.cpp | 7 +++ .../public-api/controls/image-view/image-view.h | 6 +-- 10 files changed, 135 insertions(+), 48 deletions(-) diff --git a/dali-toolkit/public-api/controls/buttons/button.cpp b/dali-toolkit/public-api/controls/buttons/button.cpp index 450d432..783e1e6 100644 --- a/dali-toolkit/public-api/controls/buttons/button.cpp +++ b/dali-toolkit/public-api/controls/buttons/button.cpp @@ -16,11 +16,12 @@ */ // CLASS HEADER - #include -// INTERNAL INCLUDES +// EXTERNAL INCLUDES +#include +// INTERNAL INCLUDES #include #include @@ -58,116 +59,162 @@ Button Button::DownCast( BaseHandle handle ) void Button::SetDisabled( bool disabled ) { + DALI_LOG_WARNING_NOFN("DEPRECATION WARNING: SetDisabled() is deprecated and will be removed from next release. Use SetProperty DISABLED or Styling file instead.\n" ); + Dali::Toolkit::GetImplementation( *this ).SetDisabled( disabled ); } bool Button::IsDisabled() const { + DALI_LOG_WARNING_NOFN("DEPRECATION WARNING: IsDisabled() is deprecated and will be removed from next release. Use GetProperty DISABLED instead.\n" ); + return Dali::Toolkit::GetImplementation( *this ).IsDisabled(); } void Button::SetAutoRepeating( bool autoRepeating ) { + DALI_LOG_WARNING_NOFN("DEPRECATION WARNING: SetAutoRepeating() is deprecated and will be removed from next release. Use SetProperty AUTO_REPEATING or Styling file instead.\n" ); + Dali::Toolkit::GetImplementation( *this ).SetAutoRepeating( autoRepeating ); } bool Button::IsAutoRepeating() const { + DALI_LOG_WARNING_NOFN("DEPRECATION WARNING: IsAutoRepeating() is deprecated and will be removed from next release. Use GetProperty AUTO_REPEATING instead.\n" ); + return Dali::Toolkit::GetImplementation( *this ).IsAutoRepeating(); } void Button::SetInitialAutoRepeatingDelay( float initialAutoRepeatingDelay ) { + DALI_LOG_WARNING_NOFN("DEPRECATION WARNING: SetInitialAutoRepeatingDelay() is deprecated and will be removed from next release. Use SetProperty INITIAL_AUTO_REPEATING_DELAY or Styling file instead.\n" ); + Dali::Toolkit::GetImplementation( *this ).SetInitialAutoRepeatingDelay( initialAutoRepeatingDelay ); } float Button::GetInitialAutoRepeatingDelay() const { + DALI_LOG_WARNING_NOFN("DEPRECATION WARNING: SetPositionInheritanceMode() is deprecated and will be removed from next release. Use GetProperty INITIAL_AUTO_REPEATING_DELAY or Styling file instead.\n" ); + return Dali::Toolkit::GetImplementation( *this ).GetInitialAutoRepeatingDelay(); } void Button::SetNextAutoRepeatingDelay( float nextAutoRepeatingDelay ) { + DALI_LOG_WARNING_NOFN("DEPRECATION WARNING: SetNextAutoRepeatingDelay() is deprecated and will be removed from next release. Use SetProperty NEXT_AUTO_REPEATING_DELAY or Styling file instead.\n" ); + Dali::Toolkit::GetImplementation( *this ).SetNextAutoRepeatingDelay( nextAutoRepeatingDelay ); } float Button::GetNextAutoRepeatingDelay() const { + DALI_LOG_WARNING_NOFN("DEPRECATION WARNING: GetNextAutoRepeatingDelay() is deprecated and will be removed from next release. Use GetProperty NEXT_AUTO_REPEATING_DELAY instead.\n" ); + return Dali::Toolkit::GetImplementation( *this ).GetNextAutoRepeatingDelay(); } void Button::SetTogglableButton( bool togglable ) { + DALI_LOG_WARNING_NOFN("DEPRECATION WARNING: SetTogglableButton() is deprecated and will be removed from next release. Use SetProperty TOGGLABLE or Styling file instead.\n" ); + Dali::Toolkit::GetImplementation( *this ).SetTogglableButton( togglable ); } bool Button::IsTogglableButton() const { + DALI_LOG_WARNING_NOFN("DEPRECATION WARNING: IsTogglableButton() is deprecated and will be removed from next release. Use GetProperty TOGGLABLE instead.\n" ); + return Dali::Toolkit::GetImplementation( *this ).IsTogglableButton(); } void Button::SetSelected( bool selected ) { + DALI_LOG_WARNING_NOFN("DEPRECATION WARNING: SetSelected() is deprecated and will be removed from next release. Use SetProperty SELECTED instead.\n" ); + Dali::Toolkit::GetImplementation( *this ).SetSelected( selected ); } bool Button::IsSelected() const { + DALI_LOG_WARNING_NOFN("DEPRECATION WARNING: IsSelected() is deprecated and will be removed from next release. Use GetProperty SELECTED instead.\n" ); + return Dali::Toolkit::GetImplementation( *this ).IsSelected(); } void Button::SetAnimationTime( float animationTime ) { + DALI_LOG_WARNING_NOFN("DEPRECATION WARNING: SetAnimationTime() is deprecated and will be removed from next release. Use Styling file to set animation instead.\n" ); + Dali::Toolkit::GetImplementation( *this ).SetAnimationTime( animationTime ); } float Button::GetAnimationTime() const { + DALI_LOG_WARNING_NOFN("DEPRECATION WARNING: GetAnimationTime() is deprecated and will be removed from next release.\n" ); + return Dali::Toolkit::GetImplementation( *this ).GetAnimationTime(); } void Button::SetLabelText( const std::string& label ) { + DALI_LOG_WARNING_NOFN("DEPRECATION WARNING: SetLabelText() is deprecated and will be removed from next release. Use SetProperty LABEL or Styling file instead.\n" ); + Dali::Toolkit::GetImplementation( *this ).SetLabelText( label ); } std::string Button::GetLabelText() const { + DALI_LOG_WARNING_NOFN("DEPRECATION WARNING: GetLabelText() is deprecated and will be removed from next release. Use GetProperty LABEL instead.\n" ); + return Dali::Toolkit::GetImplementation( *this ).GetLabelText(); } void Button::SetUnselectedImage( const std::string& filename ) { + DALI_LOG_WARNING_NOFN("DEPRECATION WARNING: SetUnselectedImage() is deprecated and will be removed from next release. Use SetProperty UNSELECTED_STATE_IMAGE or Styling file instead.\n" ); + Dali::Toolkit::GetImplementation( *this ).SetUnselectedImage( filename ); } void Button::SetBackgroundImage( const std::string& filename ) { + DALI_LOG_WARNING_NOFN("DEPRECATION WARNING: SetBackgroundImage() is deprecated and will be removed from next release. Use Styling file instead.\n" ); + Dali::Toolkit::GetImplementation( *this ).SetBackgroundImage( filename ); } void Button::SetSelectedImage( const std::string& filename ) { + DALI_LOG_WARNING_NOFN("DEPRECATION WARNING: SetSelectedImage() is deprecated and will be removed from next release. Use SetProperty SELECTED_STATE_IMAGE or Styling file instead.\n" ); + Dali::Toolkit::GetImplementation( *this ).SetSelectedImage( filename ); } void Button::SetSelectedBackgroundImage( const std::string& filename ) { + DALI_LOG_WARNING_NOFN("DEPRECATION WARNING: SetSelectedBackgroundImage() is deprecated and will be removed from next release. Use Styling file instead.\n" ); + Dali::Toolkit::GetImplementation( *this ).SetSelectedBackgroundImage( filename ); } void Button::SetDisabledBackgroundImage( const std::string& filename ) { + DALI_LOG_WARNING_NOFN("DEPRECATION WARNING: SetDisabledBackgroundImage() is deprecated and will be removed from next release. Use SetProperty DISABLED_STATE_IMAGE or Styling file instead.\n" ); + Dali::Toolkit::GetImplementation( *this ).SetDisabledBackgroundImage( filename ); } void Button::SetDisabledImage( const std::string& filename ) { + DALI_LOG_WARNING_NOFN("DEPRECATION WARNING: SetDisabledImage() is deprecated and will be removed from next release. Use Styling file instead.\n" ); + Dali::Toolkit::GetImplementation( *this ).SetDisabledImage( filename ); } void Button::SetDisabledSelectedImage( const std::string& filename ) { + DALI_LOG_WARNING_NOFN("DEPRECATION WARNING: SetDisabledSelectedImage() is deprecated and will be removed from next release. Use Styling file instead.\n" ); + Dali::Toolkit::GetImplementation( *this ).SetDisabledSelectedImage( filename ); } @@ -195,11 +242,15 @@ Button::ButtonSignalType& Button::StateChangedSignal() void Button::SetLabel( Actor label ) { + DALI_LOG_WARNING_NOFN("DEPRECATION WARNING: SetLabel() is deprecated and will be removed from next release. Use SetProperty LABEL instead.\n" ); + Dali::Toolkit::GetImplementation( *this ).SetLabel( label ); } void Button::SetButtonImage( Image image ) { + DALI_LOG_WARNING_NOFN("DEPRECATION WARNING: SetButtonImage() is deprecated and will be removed from next release. Use Styling file instead.\n" ); + Actor imageView = Toolkit::ImageView::New( image ); imageView.SetResizePolicy( ResizePolicy::USE_NATURAL_SIZE, Dimension::ALL_DIMENSIONS ); Dali::Toolkit::GetImplementation( *this ).SetButtonImage( imageView ); @@ -207,6 +258,8 @@ void Button::SetButtonImage( Image image ) void Button::SetSelectedImage( Image image ) { + DALI_LOG_WARNING_NOFN("DEPRECATION WARNING: SetSelectedImage() is deprecated and will be removed from next release. Use Styling file instead.\n" ); + Actor imageView = Toolkit::ImageView::New( image ); imageView.SetResizePolicy( ResizePolicy::USE_NATURAL_SIZE, Dimension::ALL_DIMENSIONS ); Dali::Toolkit::GetImplementation( *this ).SetSelectedImage( imageView ); @@ -214,11 +267,15 @@ void Button::SetSelectedImage( Image image ) Actor Button::GetButtonImage() const { + DALI_LOG_WARNING_NOFN("DEPRECATION WARNING: GetButtonImage() is deprecated and will be removed from next release.\n" ); + return Dali::Toolkit::GetImplementation( *this ).GetButtonImage(); } Actor Button::GetSelectedImage() const { + DALI_LOG_WARNING_NOFN("DEPRECATION WARNING: GetSelectedImage() is deprecated and will be removed from next release.\n" ); + return Dali::Toolkit::GetImplementation( *this ).GetSelectedImage(); } diff --git a/dali-toolkit/public-api/controls/buttons/button.h b/dali-toolkit/public-api/controls/buttons/button.h index 1cd6f6e..dbb0618 100644 --- a/dali-toolkit/public-api/controls/buttons/button.h +++ b/dali-toolkit/public-api/controls/buttons/button.h @@ -184,7 +184,7 @@ public: * @SINCE_1_0.0 * @param[in] disabled property. */ - void SetDisabled( bool disabled ); + void SetDisabled( bool disabled ) DALI_DEPRECATED_API; /** * @DEPRECATED_1_1.32 Use GetProperty DISABLED @@ -193,7 +193,7 @@ public: * @SINCE_1_0.0 * @return \e true if the button is \e disabled. */ - bool IsDisabled() const; + bool IsDisabled() const DALI_DEPRECATED_API; /** * @DEPRECATED_1_1.32 SetProperty AUTO_REPEATING or Styling file @@ -206,7 +206,7 @@ public: * @SINCE_1_0.0 * @param[in] autoRepeating \e autorepeating property. */ - void SetAutoRepeating( bool autoRepeating ); + void SetAutoRepeating( bool autoRepeating ) DALI_DEPRECATED_API; /** * @DEPRECATED_1_1.32 GetProperty AUTO_REPEATING @@ -215,7 +215,7 @@ public: * @SINCE_1_0.0 * @return \e true if the \e autorepeating property is set. */ - bool IsAutoRepeating() const; + bool IsAutoRepeating() const DALI_DEPRECATED_API; /** * @DEPRECATED_1_1.32 SetProperty INITIAL_AUTO_REPEATING_DELAY or Styling file @@ -228,7 +228,7 @@ public: * @param[in] initialAutoRepeatingDelay in seconds. * @pre initialAutoRepeatingDelay must be greater than zero. */ - void SetInitialAutoRepeatingDelay( float initialAutoRepeatingDelay ); + void SetInitialAutoRepeatingDelay( float initialAutoRepeatingDelay ) DALI_DEPRECATED_API; /** * @DEPRECATED_1_1.32 GetProperty INITIAL_AUTO_REPEATING_DELAY @@ -237,7 +237,7 @@ public: * @SINCE_1_0.0 * @return the initial autorepeating delay in seconds. */ - float GetInitialAutoRepeatingDelay() const; + float GetInitialAutoRepeatingDelay() const DALI_DEPRECATED_API; /** * @DEPRECATED_1_1.32 SetProperty NEXT_AUTO_REPEATING_DELAY or Styling file @@ -250,7 +250,7 @@ public: * @param[in] nextAutoRepeatingDelay in seconds. * @pre nextAutoRepeatingDelay must be greater than zero. */ - void SetNextAutoRepeatingDelay( float nextAutoRepeatingDelay ); + void SetNextAutoRepeatingDelay( float nextAutoRepeatingDelay ) DALI_DEPRECATED_API; /** * @DEPRECATED_1_1.32 GetProperty NEXT_AUTO_REPEATING_DELAY @@ -259,7 +259,7 @@ public: * @SINCE_1_0.0 * @return the next autorepeating delay in seconds. */ - float GetNextAutoRepeatingDelay() const; + float GetNextAutoRepeatingDelay() const DALI_DEPRECATED_API; /** * @DEPRECATED_1_1.32 SetProperty TOGGLABLE or Styling file @@ -271,7 +271,7 @@ public: * @SINCE_1_0.0 * @param[in] togglable property. */ - void SetTogglableButton( bool togglable ); + void SetTogglableButton( bool togglable ) DALI_DEPRECATED_API; /** * @DEPRECATED_1_1.32 GetProperty TOGGLABLE @@ -280,7 +280,7 @@ public: * @SINCE_1_0.0 * @return \e true if the \e togglable property is set. */ - bool IsTogglableButton() const; + bool IsTogglableButton() const DALI_DEPRECATED_API; /** * @DEPRECATED_1_1.32 SetProperty SELECTED @@ -294,16 +294,16 @@ public: * @SINCE_1_0.0 * @param[in] selected property. */ - void SetSelected( bool selected ); + void SetSelected( bool selected ) DALI_DEPRECATED_API; /** - * DEPRECATED_1_1.32 SetProperty SELECTED + * DEPRECATED_1_1.32 GetProperty SELECTED * * @brief Returns if the selected property is set and the button is togglable. * @SINCE_1_0.0 * @return \e true if the button is \e selected. */ - bool IsSelected() const; + bool IsSelected() const DALI_DEPRECATED_API; /** * @DEPRECATED_1_1.32 Use Styling file to set animation @@ -313,7 +313,7 @@ public: * @SINCE_1_0.0 * @param[in] animationTime The animation time in seconds. */ - void SetAnimationTime( float animationTime ); + void SetAnimationTime( float animationTime ) DALI_DEPRECATED_API; /** * DEPRECATED_1_1.32 Use Styling file to set animation @@ -323,7 +323,7 @@ public: * @SINCE_1_0.0 * @return The animation time in seconds. */ - float GetAnimationTime() const; + float GetAnimationTime() const DALI_DEPRECATED_API; /** * @DEPRECATED_1_1.32 SetProperty LABEL or Styling file @@ -333,7 +333,7 @@ public: * @SINCE_1_0.0 * @param[in] label The label text. */ - void SetLabelText( const std::string& label ); + void SetLabelText( const std::string& label ) DALI_DEPRECATED_API; /** * DEPRECATED_1_1.32 GetProperty LABEL @@ -343,7 +343,7 @@ public: * @SINCE_1_0.0 * @return The label text. */ - std::string GetLabelText() const; + std::string GetLabelText() const DALI_DEPRECATED_API; /** * @DEPRECATED_1_1.32 Use Styling file @@ -353,7 +353,7 @@ public: * @SINCE_1_0.0 * @param[in] filename The button image. */ - void SetUnselectedImage( const std::string& filename ); + void SetUnselectedImage( const std::string& filename ) DALI_DEPRECATED_API; /** * @DEPRECATED_1_1.32 Use styling @@ -363,7 +363,7 @@ public: * @SINCE_1_0.0 * @param[in] filename The background image. */ - void SetBackgroundImage( const std::string& filename ); + void SetBackgroundImage( const std::string& filename ) DALI_DEPRECATED_API; /** * @DEPRECATED_1_1.32 Use styling file @@ -373,7 +373,7 @@ public: * @SINCE_1_0.0 * @param[in] filename The selected image. */ - void SetSelectedImage( const std::string& filename ); + void SetSelectedImage( const std::string& filename ) DALI_DEPRECATED_API; /** * @DEPRECATED_1_1.32 Use styling file @@ -383,7 +383,7 @@ public: * @SINCE_1_0.0 * @param[in] filename The selected background image. */ - void SetSelectedBackgroundImage( const std::string& filename ); + void SetSelectedBackgroundImage( const std::string& filename ) DALI_DEPRECATED_API; /** * @DEPRECATED_1_1.32 Use styling file @@ -393,7 +393,7 @@ public: * @SINCE_1_0.0 * @param[in] filename The disabled background image. */ - void SetDisabledBackgroundImage( const std::string& filename ); + void SetDisabledBackgroundImage( const std::string& filename ) DALI_DEPRECATED_API; /** * @DEPRECATED_1_1.32 Use styling file @@ -403,7 +403,7 @@ public: * @SINCE_1_0.0 * @param[in] filename The disabled button image. */ - void SetDisabledImage( const std::string& filename ); + void SetDisabledImage( const std::string& filename ) DALI_DEPRECATED_API; /** * @DEPRECATED_1_1.32 Use styling file @@ -413,7 +413,7 @@ public: * @SINCE_1_0.0 * @param[in] filename The disabled selected button image. */ - void SetDisabledSelectedImage( const std::string& filename ); + void SetDisabledSelectedImage( const std::string& filename ) DALI_DEPRECATED_API; /** * @DEPRECATED_1_0.50. Instead, use SetLabelText. @@ -423,7 +423,7 @@ public: * @SINCE_1_0.0 * @param[in] label The actor to use as a label */ - void SetLabel( Actor label ); + void SetLabel( Actor label ) DALI_DEPRECATED_API; /** * @DEPRECATED_1_0.50. Instead, use SetUnselectedImage. @@ -433,7 +433,7 @@ public: * @SINCE_1_0.0 * @param[in] image The button image. */ - void SetButtonImage( Image image ); + void SetButtonImage( Image image ) DALI_DEPRECATED_API; /** * @DEPRECATED_1_0.50. Instead, use SetSelectedImage( const std::string& filename ). @@ -443,7 +443,7 @@ public: * @SINCE_1_0.0 * @param[in] image The selected image. */ - void SetSelectedImage( Image image ); + void SetSelectedImage( Image image ) DALI_DEPRECATED_API; /** * @DEPRECATED_1_0.50 @@ -454,7 +454,7 @@ public: * @remarks Avoid using this method as it's a legacy code. * @return An actor with the button image. */ - Actor GetButtonImage() const; + Actor GetButtonImage() const DALI_DEPRECATED_API; /** * @DEPRECATED_1_0.50 @@ -465,7 +465,7 @@ public: * @remarks Avoid using this method as it's a legacy code. * @return An actor with the selected image. */ - Actor GetSelectedImage() const; + Actor GetSelectedImage() const DALI_DEPRECATED_API; public: //Signals diff --git a/dali-toolkit/public-api/controls/buttons/push-button.cpp b/dali-toolkit/public-api/controls/buttons/push-button.cpp index 90fcefd..5e40b55 100644 --- a/dali-toolkit/public-api/controls/buttons/push-button.cpp +++ b/dali-toolkit/public-api/controls/buttons/push-button.cpp @@ -16,11 +16,12 @@ */ // CLASS HEADER - #include -// INTERNAL INCLUDES +// EXTERNAL INCLUDES +#include +// INTERNAL INCLUDES #include namespace Dali @@ -77,36 +78,50 @@ PushButton PushButton::DownCast( BaseHandle handle ) void PushButton::SetButtonImage( Actor 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" ); + Dali::Toolkit::GetImplementation( *this ).SetButtonImage( image ); } void PushButton::SetBackgroundImage( Actor image ) { + DALI_LOG_WARNING_NOFN("DEPRECATION WARNING: SetBackgroundImage() is deprecated and will be removed from next release.\n" ); + Dali::Toolkit::GetImplementation( *this ).SetBackgroundImage( image ); } void PushButton::SetSelectedImage( Actor 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" ); + Dali::Toolkit::GetImplementation( *this ).SetSelectedImage( image ); } void PushButton::SetSelectedBackgroundImage( Actor image ) { + DALI_LOG_WARNING_NOFN("DEPRECATION WARNING: SetSelectedBackgroundImage() is deprecated and will be removed from next release.\n" ); + Dali::Toolkit::GetImplementation( *this ).SetSelectedBackgroundImage( image ); } void PushButton::SetDisabledBackgroundImage( Actor image ) { + DALI_LOG_WARNING_NOFN("DEPRECATION WARNING: SetDisabledBackgroundImage() is deprecated and will be removed from next release.\n" ); + 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 ); } void PushButton::SetDisabledSelectedImage( Actor image ) { + DALI_LOG_WARNING_NOFN("DEPRECATION WARNING: SetDisabledSelectedImage() is deprecated and will be removed from next release.\n" ); + Dali::Toolkit::GetImplementation( *this ).SetDisabledSelectedImage( image ); } diff --git a/dali-toolkit/public-api/controls/buttons/push-button.h b/dali-toolkit/public-api/controls/buttons/push-button.h index 8551851..6142413 100644 --- a/dali-toolkit/public-api/controls/buttons/push-button.h +++ b/dali-toolkit/public-api/controls/buttons/push-button.h @@ -185,7 +185,7 @@ public: * @SINCE_1_0.0 * @param[in] image The Actor to use. */ - void SetButtonImage( Actor image ); + void SetButtonImage( Actor image ) DALI_DEPRECATED_API; using Button::SetBackgroundImage; @@ -197,7 +197,7 @@ public: * @SINCE_1_0.0 * @param[in] image The Actor to use. */ - void SetBackgroundImage( Actor image ); + void SetBackgroundImage( Actor image ) DALI_DEPRECATED_API; using Button::SetSelectedImage; @@ -209,7 +209,7 @@ public: * @SINCE_1_0.0 * @param[in] image The Actor to use. */ - void SetSelectedImage( Actor image ); + void SetSelectedImage( Actor image ) DALI_DEPRECATED_API; using Button::SetSelectedBackgroundImage; @@ -221,7 +221,7 @@ public: * @SINCE_1_0.0 * @param[in] image The Actor to use. */ - void SetSelectedBackgroundImage( Actor image ); + void SetSelectedBackgroundImage( Actor image ) DALI_DEPRECATED_API; using Button::SetDisabledBackgroundImage; @@ -233,7 +233,7 @@ public: * @SINCE_1_0.0 * @param[in] image The Actor to use. */ - void SetDisabledBackgroundImage( Actor image ); + void SetDisabledBackgroundImage( Actor image ) DALI_DEPRECATED_API; using Button::SetDisabledImage; @@ -245,7 +245,7 @@ public: * @SINCE_1_0.0 * @param[in] image The Actor to use. */ - void SetDisabledImage( Actor image ); + void SetDisabledImage( Actor image ) DALI_DEPRECATED_API; using Button::SetDisabledSelectedImage; @@ -257,7 +257,7 @@ public: * @SINCE_1_0.0 * @param[in] image The Actor to use. */ - void SetDisabledSelectedImage( Actor image ); + void SetDisabledSelectedImage( Actor image ) DALI_DEPRECATED_API; public: // Not intended for application developers diff --git a/dali-toolkit/public-api/controls/control-impl.cpp b/dali-toolkit/public-api/controls/control-impl.cpp index b71a080..2ac22fa 100644 --- a/dali-toolkit/public-api/controls/control-impl.cpp +++ b/dali-toolkit/public-api/controls/control-impl.cpp @@ -604,7 +604,6 @@ void Control::SetBackground( const Property::Map& map ) void Control::SetBackgroundImage( Image image ) { - DALI_LOG_WARNING( "SetBackgroundImage is for the depreciated Property::BACKGROUND_IMAGE use SetBackground( const Property::Map& map )\n" ); Toolkit::Visual::Base visual = Toolkit::VisualFactory::Get().CreateVisual( image ); if( visual ) { @@ -1047,10 +1046,12 @@ void Control::OnInitialize() void Control::OnControlChildAdd( Actor& child ) { + DALI_LOG_WARNING_NOFN("DEPRECATION WARNING: OnControlChildAdd() is deprecated and will be removed from next release. Override OnChildAdd instead.\n" ); } void Control::OnControlChildRemove( Actor& child ) { + DALI_LOG_WARNING_NOFN("DEPRECATION WARNING: OnControlChildRemove() is deprecated and will be removed from next release. Override OnChildRemove instead.\n" ); } void Control::OnStyleChange( Toolkit::StyleManager styleManager, StyleChange::Type change ) diff --git a/dali-toolkit/public-api/controls/control-impl.h b/dali-toolkit/public-api/controls/control-impl.h index 95ea152..62d087b 100644 --- a/dali-toolkit/public-api/controls/control-impl.h +++ b/dali-toolkit/public-api/controls/control-impl.h @@ -547,7 +547,7 @@ public: // API for derived classes to override * @SINCE_1_0.0 * @param[in] child The added actor. */ - virtual void OnControlChildAdd( Actor& child ); + virtual void OnControlChildAdd( Actor& child ) DALI_DEPRECATED_API; /** * @DEPRECATED_1_1.30. Override OnChildRemove instead. @@ -559,7 +559,7 @@ public: // API for derived classes to override * @SINCE_1_0.0 * @param[in] child The removed actor. */ - virtual void OnControlChildRemove( Actor& child ); + virtual void OnControlChildRemove( Actor& child ) DALI_DEPRECATED_API; // Styling diff --git a/dali-toolkit/public-api/controls/control.cpp b/dali-toolkit/public-api/controls/control.cpp index 18eaeeb..b83a652 100644 --- a/dali-toolkit/public-api/controls/control.cpp +++ b/dali-toolkit/public-api/controls/control.cpp @@ -18,6 +18,9 @@ // CLASS HEADER #include +// EXTERNAL INCLUDES +#include + // INTERNAL INCLUDES #include @@ -106,11 +109,15 @@ const std::string& Control::GetStyleName() const void Control::SetBackgroundColor( const Vector4& color ) { + DALI_LOG_WARNING_NOFN("DEPRECATION WARNING: SetBackgroundImage() is deprecated and will be removed from next release. use Property::BACKGROUND instead.\n" ); + Internal::GetImplementation(*this).SetBackgroundColor( color ); } Vector4 Control::GetBackgroundColor() const { + DALI_LOG_WARNING_NOFN("DEPRECATION WARNING: GetBackgroundColor() is deprecated and will be removed from next release. use Property::BACKGROUND instead.\n" ); + return Internal::GetImplementation(*this).GetBackgroundColor(); } diff --git a/dali-toolkit/public-api/controls/control.h b/dali-toolkit/public-api/controls/control.h index e9200d6..f91a036 100644 --- a/dali-toolkit/public-api/controls/control.h +++ b/dali-toolkit/public-api/controls/control.h @@ -330,7 +330,7 @@ public: * @SINCE_1_0.0 * @return The background color of the control. */ - Vector4 GetBackgroundColor() const; + Vector4 GetBackgroundColor() const DALI_DEPRECATED_API; /** * @DEPRECATED_1_2_8, use Property::BACKGROUND instead @@ -340,7 +340,7 @@ public: * @SINCE_1_0.0 * @param[in] image The image to set as the background. */ - void SetBackgroundImage( Image image ); + void SetBackgroundImage( Image image ) DALI_DEPRECATED_API; /** * @brief Clears the background. diff --git a/dali-toolkit/public-api/controls/image-view/image-view.cpp b/dali-toolkit/public-api/controls/image-view/image-view.cpp index 2726af5..02d3e0d 100644 --- a/dali-toolkit/public-api/controls/image-view/image-view.cpp +++ b/dali-toolkit/public-api/controls/image-view/image-view.cpp @@ -19,6 +19,7 @@ #include // EXTERNAL INCLUDES +#include #include #include @@ -60,6 +61,8 @@ ImageView ImageView::New() ImageView ImageView::New( Image image ) { + DALI_LOG_WARNING_NOFN("DEPRECATION WARNING: New() is deprecated and will be removed from next release. use New( const std::string& ) instead.\n" ); + ImageView imageView = Internal::ImageView::New(); imageView.SetImage( image ); return imageView; @@ -86,6 +89,8 @@ ImageView ImageView::DownCast( BaseHandle handle ) void ImageView::SetImage( Image image ) { + DALI_LOG_WARNING_NOFN("DEPRECATION WARNING: SetImage() is deprecated and will be removed from next release. Use SetImage( const std::string& ) instead.\n" ); + Dali::Toolkit::GetImpl( *this ).SetImage( image ); } @@ -101,6 +106,8 @@ void ImageView::SetImage( const std::string& url, ImageDimensions size ) Image ImageView::GetImage() const { + DALI_LOG_WARNING_NOFN("DEPRECATION WARNING: GetImage() is deprecated and will be removed from next release.\n" ); + return Dali::Toolkit::GetImpl( *this ).GetImage(); } diff --git a/dali-toolkit/public-api/controls/image-view/image-view.h b/dali-toolkit/public-api/controls/image-view/image-view.h index 3d4c361..7954884 100644 --- a/dali-toolkit/public-api/controls/image-view/image-view.h +++ b/dali-toolkit/public-api/controls/image-view/image-view.h @@ -139,7 +139,7 @@ public: * @param[in] image The Image instance to display. * @return A handle to a newly allocated ImageView. */ - static ImageView New( Image image ); + static ImageView New( Image image ) DALI_DEPRECATED_API; /** * @brief Create an initialized ImageView from an URL to an image resource. @@ -218,7 +218,7 @@ public: * @SINCE_1_0.0 * @param[in] image The Image instance to display. */ - void SetImage( Image image ); + void SetImage( Image image ) DALI_DEPRECATED_API; /** * @brief Sets this ImageView from the given URL. @@ -254,7 +254,7 @@ public: * @SINCE_1_0.0 * @return The Image instance currently used by the ImageView. */ - Image GetImage() const; + Image GetImage() const DALI_DEPRECATED_API; public: // Not intended for application developers -- 2.7.4