X-Git-Url: http://review.tizen.org/git/?p=platform%2Fcore%2Fuifw%2Fdali-toolkit.git;a=blobdiff_plain;f=dali-toolkit%2Finternal%2Fcontrols%2Ftext-controls%2Ftext-selection-popup-impl.cpp;h=459e53461e2f235fbb71164355e4d17668c546b6;hp=22486683dbdfd7e2f47cea062feaae87e70113c3;hb=84d36f3df81b55d0c7ae20db8005a28742fa4060;hpb=cbff244b295bcd2758fe93155a9b3199d85ee164 diff --git a/dali-toolkit/internal/controls/text-controls/text-selection-popup-impl.cpp b/dali-toolkit/internal/controls/text-controls/text-selection-popup-impl.cpp index 2248668..459e534 100644 --- a/dali-toolkit/internal/controls/text-controls/text-selection-popup-impl.cpp +++ b/dali-toolkit/internal/controls/text-controls/text-selection-popup-impl.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. @@ -22,7 +22,7 @@ #include #include #include -#include +#include #include #include #include @@ -34,6 +34,8 @@ #include #include #include +#include +#include namespace Dali { @@ -386,15 +388,10 @@ void TextSelectionPopup::OnInitialize() Actor self = Self(); self.SetResizePolicy( ResizePolicy::FIT_TO_CHILDREN, Dimension::ALL_DIMENSIONS ); self.SetProperty( Actor::Property::COLOR_ALPHA, 0.0f ); -} - -void TextSelectionPopup::OnStageConnection( int depth ) -{ - DALI_LOG_INFO( gLogFilter, Debug::General, "TextSelectionPopup::OnStageConnection\n" ); - // Call the Control::OnStageConnection() to set the depth of the background. - Control::OnStageConnection( depth ); - // TextSelectionToolbar::OnStageConnection() will set the depths of all the popup's components. + // The Popup Control background is a nine-patch image. We clip against this so the + // contents are correctly clipped against the edges of the nine-patch. + self.SetProperty( Actor::Property::CLIPPING_MODE, ClippingMode::CLIP_CHILDREN ); } void TextSelectionPopup::HideAnimationFinished( Animation& animation ) @@ -705,7 +702,7 @@ std::string TextSelectionPopup::GetPressedImage() const // Label properties. Property::Map buttonLabelProperties; - buttonLabelProperties.Insert( "text", button.caption ); + buttonLabelProperties.Insert( Toolkit::TextVisual::Property::TEXT, button.caption ); option.SetProperty( Toolkit::Button::Property::LABEL, buttonLabelProperties ); } if( showIcons ) @@ -800,7 +797,7 @@ std::string TextSelectionPopup::GetPressedImage() const } TextSelectionPopup::TextSelectionPopup( TextSelectionPopupCallbackInterface* callbackInterface ) -: Control( ControlBehaviour( REQUIRES_STYLE_CHANGE_SIGNALS ) ), +: Control( ControlBehaviour( CONTROL_BEHAVIOUR_DEFAULT ) ), mToolbar(), mPopupMaxSize(), mOptionMaxSize(),