From: Adeel Kazmi Date: Wed, 28 Dec 2016 14:11:44 +0000 (+0000) Subject: Stop using deprecated API from Popup and fix typo in Control X-Git-Tag: dali_1.2.20~2 X-Git-Url: http://review.tizen.org/git/?p=platform%2Fcore%2Fuifw%2Fdali-toolkit.git;a=commitdiff_plain;h=306ab4095235efd0289e9da4e3994f456cbda2aa;hp=5ccf4084ffd4dfb3fafa54d39ce091626f988135;ds=sidebyside Stop using deprecated API from Popup and fix typo in Control Change-Id: I8ff603aa1af813fa5e0bf614ebae815ddca7af6e --- diff --git a/dali-toolkit/internal/controls/popup/popup-impl.cpp b/dali-toolkit/internal/controls/popup/popup-impl.cpp index 681d6b4..d12e273 100644 --- a/dali-toolkit/internal/controls/popup/popup-impl.cpp +++ b/dali-toolkit/internal/controls/popup/popup-impl.cpp @@ -37,6 +37,8 @@ #include #include #include +#include +#include #include using namespace Dali; @@ -908,7 +910,9 @@ Toolkit::Popup::ContextualMode Popup::GetContextualMode() const Toolkit::Control Popup::CreateBacking() { Toolkit::Control backing = Control::New(); - backing.SetBackgroundColor( Vector4( mBackingColor.r, mBackingColor.g, mBackingColor.b, 1.0f ) ); + backing.SetProperty( Toolkit::Control::Property::BACKGROUND, + Property::Map().Add( Toolkit::Visual::Property::TYPE, Toolkit::Visual::COLOR ) + .Add( Toolkit::ColorVisual::Property::MIX_COLOR, Vector4( mBackingColor.r, mBackingColor.g, mBackingColor.b, 1.0f ) ) ); backing.SetName( "popupBacking" ); // Must always be positioned top-left of stage, regardless of parent. diff --git a/dali-toolkit/public-api/controls/control.cpp b/dali-toolkit/public-api/controls/control.cpp index b83a652..415ffb6 100644 --- a/dali-toolkit/public-api/controls/control.cpp +++ b/dali-toolkit/public-api/controls/control.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015 Samsung Electronics Co., Ltd. + * Copyright (c) 2016 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. @@ -109,7 +109,7 @@ 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" ); + DALI_LOG_WARNING_NOFN("DEPRECATION WARNING: SetBackgroundColor() is deprecated and will be removed from next release. use Property::BACKGROUND instead.\n" ); Internal::GetImplementation(*this).SetBackgroundColor( color ); }