X-Git-Url: http://review.tizen.org/git/?p=platform%2Fcore%2Fuifw%2Fdali-toolkit.git;a=blobdiff_plain;f=automated-tests%2Fsrc%2Fdali-toolkit%2Fdali-toolkit-test-utils%2Ftoolkit-adaptor.cpp;h=3ff177c2d3afe1775fb1cf1fab6984d7b2d501a8;hp=4b25c5da0f4e9ea71e35a349ab532c92b7009921;hb=09fea2d3984ac0100f87f480335d674cbb9384a1;hpb=92a400c3857fbf6c1e63693f22c94dcffe50e522 diff --git a/automated-tests/src/dali-toolkit/dali-toolkit-test-utils/toolkit-adaptor.cpp b/automated-tests/src/dali-toolkit/dali-toolkit-test-utils/toolkit-adaptor.cpp index 4b25c5d..3ff177c 100644 --- a/automated-tests/src/dali-toolkit/dali-toolkit-test-utils/toolkit-adaptor.cpp +++ b/automated-tests/src/dali-toolkit/dali-toolkit-test-utils/toolkit-adaptor.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016 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. @@ -21,6 +21,8 @@ #include #include +#include +#include namespace Dali { @@ -210,6 +212,34 @@ void Adaptor::SetStereoBase( float stereoBase ) { } + +class LogFactory : public LogFactoryInterface +{ +public: + virtual void InstallLogFunction() const + { + Dali::Integration::Log::LogFunction logFunction(&TestApplication::LogMessage); + Dali::Integration::Log::InstallLogFunction(logFunction); + } + + LogFactory() + { + } + virtual ~LogFactory() + { + } +}; + +LogFactory* gLogFactory = NULL; +const LogFactoryInterface& Adaptor::GetLogFactory() +{ + if( gLogFactory == NULL ) + { + gLogFactory = new LogFactory; + } + return *gLogFactory; +} + Adaptor::Adaptor() : mImpl( NULL ) {