X-Git-Url: http://review.tizen.org/git/?p=platform%2Fcore%2Fuifw%2Fdali-toolkit.git;a=blobdiff_plain;f=base%2Fdali-toolkit%2Fpublic-api%2Fbuilder%2Fbuilder.cpp;h=bd85719c44914c87fb1f6708f87a2c405c831284;hp=dbb75b1a3a2e2b55569bb2cc4c994ce2921a0fcd;hb=87b3b1f9a40c85ab6120d77bc6c0d356ae45faf3;hpb=022b76df6f53c2860f2684ef1ffee81af1805e2e diff --git a/base/dali-toolkit/public-api/builder/builder.cpp b/base/dali-toolkit/public-api/builder/builder.cpp index dbb75b1..bd85719 100644 --- a/base/dali-toolkit/public-api/builder/builder.cpp +++ b/base/dali-toolkit/public-api/builder/builder.cpp @@ -1,18 +1,19 @@ -// -// Copyright (c) 2014 Samsung Electronics Co., Ltd. -// -// Licensed under the Flora License, Version 1.0 (the License); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://floralicense.org/license/ -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an AS IS BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// +/* + * Copyright (c) 2014 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. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * + */ // CLASS HEADER @@ -53,7 +54,7 @@ void Builder::LoadFromString( const std::string &data, UIFormat rep ) GetImpl(*this).LoadFromString( data ); } -void Builder::AddConstants( const PropertyValueMap& map ) +void Builder::AddConstants( const Property::Map& map ) { GetImpl(*this).AddConstants( map ); } @@ -63,7 +64,7 @@ void Builder::AddConstant( const std::string& key, const Property::Value& value GetImpl(*this).AddConstant( key, value ); } -const PropertyValueMap& Builder::GetConstants() const +const Property::Map& Builder::GetConstants() const { return GetImpl(*this).GetConstants(); } @@ -78,7 +79,7 @@ Animation Builder::CreateAnimation( const std::string& animationName ) return GetImpl(*this).CreateAnimation( animationName ); } -Animation Builder::CreateAnimation( const std::string& animationName, const PropertyValueMap& map ) +Animation Builder::CreateAnimation( const std::string& animationName, const Property::Map& map ) { return GetImpl(*this).CreateAnimation( animationName, map ); } @@ -88,34 +89,34 @@ Animation Builder::CreateAnimation( const std::string& animationName, Dali::Acto return GetImpl(*this).CreateAnimation( animationName, sourceActor ); } -Animation Builder::CreateAnimation( const std::string& animationName, const PropertyValueMap& map, Dali::Actor sourceActor ) +Animation Builder::CreateAnimation( const std::string& animationName, const Property::Map& map, Dali::Actor sourceActor ) { return GetImpl(*this).CreateAnimation( animationName, map, sourceActor ); } -BaseHandle Builder::CreateFromStyle( const std::string& styleName ) +BaseHandle Builder::Create( const std::string& templateName ) { - return BaseHandle(); + return GetImpl(*this).Create( templateName ); } -BaseHandle Builder::CreateFromStyle( const std::string& styleName, const PropertyValueMap& map ) +BaseHandle Builder::Create( const std::string& templateName, const Property::Map& map ) { - return BaseHandle(); + return GetImpl(*this).Create( templateName, map ); } -BaseHandle Builder::Create( const std::string& templateName ) +BaseHandle Builder::CreateFromJson( const std::string& json ) { - return GetImpl(*this).Create( templateName ); + return GetImpl(*this).CreateFromJson( json ); } -BaseHandle Builder::Create( const std::string& templateName, const PropertyValueMap& map ) +bool Builder::ApplyStyle( const std::string& styleName, Handle& handle ) { - return GetImpl(*this).Create( templateName, map ); + return GetImpl(*this).ApplyStyle( styleName, handle ); } -bool Builder::ApplyStyle( const std::string& styleName, Handle& handle ) +bool Builder::ApplyFromJson( Handle& handle, const std::string& json ) { - return GetImpl(*this).ApplyStyle( styleName, handle ); + return GetImpl(*this).ApplyFromJson( handle, json ); } void Builder::AddActors( Actor toActor ) @@ -128,31 +129,6 @@ void Builder::AddActors( const std::string §ionName, Actor toActor ) GetImpl(*this).AddActors( sectionName, toActor ); } -Font Builder::GetFont( const std::string &name ) const -{ - return GetImpl(*this).GetFont( name ); -} - -TextStyle Builder::GetTextStyle( const std::string &name ) const -{ - return GetImpl(*this).GetTextStyle( name ); -} - -Image Builder::GetImage( const std::string &name ) const -{ - return GetImpl(*this).GetImage( name ); -} - -Actor Builder::GetActor( const std::string &name ) const -{ - return GetImpl(*this).GetActor( name ); -} - -Animation Builder::GetAnimation( const std::string &name ) const -{ - return GetImpl(*this).GetAnimation( name ); -} - void Builder::CreateRenderTask( const std::string &name ) { GetImpl(*this).CreateRenderTask( name ); @@ -168,9 +144,14 @@ FrameBufferImage Builder::GetFrameBufferImage( const std::string &name ) return GetImpl(*this).GetFrameBufferImage( name ); } -ActorContainer Builder::GetTopLevelActors( void ) const +Path Builder::GetPath( const std::string &name ) +{ + return GetImpl(*this).GetPath( name ); +} + +Builder::Signal& Builder::QuitSignal() { - return GetImpl(*this).GetTopLevelActors(); + return GetImpl( *this ).QuitSignal(); } } // namespace Toolkit