From 01fb482a241677ba0ac648e3862bd70ee1672472 Mon Sep 17 00:00:00 2001 From: Adeel Kazmi Date: Wed, 18 Jan 2017 12:07:48 +0000 Subject: [PATCH] Remove usage of deprecated Button::SetLabelText Change-Id: Ib82cf26ecd384f987e6567353fc7984e8781c19f --- dali-toolkit/public-api/controls/buttons/check-box-button.h | 4 ++-- dali-toolkit/public-api/controls/buttons/push-button.h | 4 ++-- dali-toolkit/public-api/controls/buttons/radio-button.cpp | 4 ++-- dali-toolkit/public-api/controls/buttons/radio-button.h | 8 ++++---- 4 files changed, 10 insertions(+), 10 deletions(-) diff --git a/dali-toolkit/public-api/controls/buttons/check-box-button.h b/dali-toolkit/public-api/controls/buttons/check-box-button.h index 105f784..4473734 100644 --- a/dali-toolkit/public-api/controls/buttons/check-box-button.h +++ b/dali-toolkit/public-api/controls/buttons/check-box-button.h @@ -2,7 +2,7 @@ #define __DALI_TOOLKIT_CHECK_BOX_BUTTON_H__ /* - * Copyright (c) 2015 Samsung Electronics Co., Ltd. + * Copyright (c) 2017 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. @@ -60,7 +60,7 @@ class CheckBoxButton; * { * CheckBoxButton button = CheckBoxButton::New(); * button.SetParentOrigin( ParentOrigin::CENTER ); - * button.SetLabelText( "Check" ); + * button.SetProperty( Button::Property::LABEL, "Check" ); * button.SetSize( 200, 40 ); * button.SetBackgroundColor( Color::WHITE ); * Stage::GetCurrent().Add( button ); diff --git a/dali-toolkit/public-api/controls/buttons/push-button.h b/dali-toolkit/public-api/controls/buttons/push-button.h index f0d2e29..c0535fe 100644 --- a/dali-toolkit/public-api/controls/buttons/push-button.h +++ b/dali-toolkit/public-api/controls/buttons/push-button.h @@ -2,7 +2,7 @@ #define __DALI_TOOLKIT_PUSH_BUTTON_H__ /* - * Copyright (c) 2015 Samsung Electronics Co., Ltd. + * Copyright (c) 2017 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. @@ -54,7 +54,7 @@ class PushButton; * { * PushButton button = PushButton::New(); * button.SetParentOrigin( ParentOrigin::CENTER ); - * button.SetLabelText( "Press" ); + * button.SetProperty( Button::Property::LABEL, "Press" ); * Stage::GetCurrent().Add( button ); * * // Connect to button signals emitted by the button diff --git a/dali-toolkit/public-api/controls/buttons/radio-button.cpp b/dali-toolkit/public-api/controls/buttons/radio-button.cpp index 0802b74..7538723 100644 --- a/dali-toolkit/public-api/controls/buttons/radio-button.cpp +++ b/dali-toolkit/public-api/controls/buttons/radio-button.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015 Samsung Electronics Co., Ltd. + * Copyright (c) 2017 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. @@ -71,7 +71,7 @@ RadioButton RadioButton::New() RadioButton RadioButton::New( const std::string& label ) { RadioButton radioButton = Internal::RadioButton::New(); - radioButton.SetLabelText( label ); + radioButton.SetProperty( Toolkit::Button::Property::LABEL, label ); return radioButton; } diff --git a/dali-toolkit/public-api/controls/buttons/radio-button.h b/dali-toolkit/public-api/controls/buttons/radio-button.h index 0bc276e..99a4815 100644 --- a/dali-toolkit/public-api/controls/buttons/radio-button.h +++ b/dali-toolkit/public-api/controls/buttons/radio-button.h @@ -2,7 +2,7 @@ #define __DALI_TOOLKIT_RADIO_BUTTON_H__ /* - * Copyright (c) 2015 Samsung Electronics Co., Ltd. + * Copyright (c) 2017 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. @@ -45,7 +45,7 @@ class RadioButton; * * Radio buttons are designed to select one of many option at the same time. * - * Every button have its own \e label and \e state, which can be modified by Button::SetLabelText and Button::SetSelected. + * Every button have its own \e label and \e state, which can be modified by Button::Property::LABEL and Button::Property::SELECTED. * * RadioButton can change its current state using Button::SetSelected. * @@ -69,14 +69,14 @@ class RadioButton; * * // Make the first RadioButton and add it to its parent * RadioButton button1 = RadioButton::New(); - * button1.SetLabelText( "button1" ); + * button1.SetProperty( Button::Property::LABEL, "button1" ); * button1.SetBackgroundColor( Color::WHITE ); * button1.SetPosition( 0, -40 ); * radioGroup.Add( button1 ); * * // Make more RadioButtons and add them to their parent * RadioButton button2 = RadioButton::New(); - * button2.SetLabelText( "button2" ); + * button2.SetProperty( Toolkit::Button::Property::LABEL, "button2" ); * button2.SetBackgroundColor( Color::WHITE ); * button2.SetPosition( 0, 40 ); * radioGroup.Add( button2 ); -- 2.7.4