X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=examples%2Fcontact-cards%2Fmasked-image.cpp;h=2279b8a64f734c8c5ee37edbe7ae1585834844de;hb=1b19fd140ff139b5854a1a62447faf31b175d8f6;hp=abf7001fe0f4fb61dc47914e39aa2effcfe6f803;hpb=c52663f9491be4983c66c0ecd38ce4aafebab5ea;p=platform%2Fcore%2Fuifw%2Fdali-demo.git diff --git a/examples/contact-cards/masked-image.cpp b/examples/contact-cards/masked-image.cpp index abf7001..2279b8a 100644 --- a/examples/contact-cards/masked-image.cpp +++ b/examples/contact-cards/masked-image.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2018 Samsung Electronics Co., Ltd. + * Copyright (c) 2020 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. @@ -23,25 +23,23 @@ namespace MaskedImage { - using namespace Dali; using namespace Dali::Toolkit; namespace { -const char* const IMAGE_MASK ( DEMO_IMAGE_DIR "contact-cards-mask.png" ); +const char* const IMAGE_MASK(DEMO_IMAGE_DIR "contact-cards-mask.png"); } // unnamed namespace -Dali::Toolkit::Control Create( const std::string& imagePath ) +Dali::Toolkit::Control Create(const std::string& imagePath) { Control maskedImage = ImageView::New(); maskedImage.SetProperty( Toolkit::ImageView::Property::IMAGE, - Property::Map().Add( Visual::Property::TYPE, Toolkit::Visual::Type::IMAGE ) - .Add( ImageVisual::Property::URL, imagePath ) - .Add( ImageVisual::Property::ALPHA_MASK_URL, IMAGE_MASK ) - ); + Property::Map{{Visual::Property::TYPE, Toolkit::Visual::Type::IMAGE}, + {ImageVisual::Property::URL, imagePath}, + {ImageVisual::Property::ALPHA_MASK_URL, IMAGE_MASK}}); return maskedImage; } -} // namespace ClippedImage +} // namespace MaskedImage