From: Anton Obzhirov Date: Mon, 24 Jun 2019 10:36:52 +0000 (+0100) Subject: Move trace factory Ubuntu implementation to generic. X-Git-Tag: dali_1.4.26~5 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=refs%2Fchanges%2F50%2F208450%2F3;p=platform%2Fcore%2Fuifw%2Fdali-adaptor.git Move trace factory Ubuntu implementation to generic. Change-Id: Ic34941ea014408a844a3d2777c87a375392e190f --- diff --git a/dali/internal/trace/file.list b/dali/internal/trace/file.list index 9b94bd6..833aa4e 100644 --- a/dali/internal/trace/file.list +++ b/dali/internal/trace/file.list @@ -7,10 +7,10 @@ adaptor_trace_common_src_files=\ # module: trace, backend: ubuntu adaptor_trace_ubuntu_src_files=\ - ${adaptor_trace_dir}/ubuntu/trace-manager-impl-ubuntu.cpp \ - ${adaptor_trace_dir}/ubuntu/trace-factory-ubuntu.cpp + ${adaptor_trace_dir}/generic/trace-manager-impl-generic.cpp \ + ${adaptor_trace_dir}/generic/trace-factory-generic.cpp # module: trace, backend: tizen adaptor_trace_tizen_src_files=\ ${adaptor_trace_dir}/tizen/trace-manager-impl-tizen.cpp \ - ${adaptor_trace_dir}/tizen/trace-factory-tizen.cpp \ No newline at end of file + ${adaptor_trace_dir}/tizen/trace-factory-tizen.cpp diff --git a/dali/internal/trace/ubuntu/trace-factory-ubuntu.cpp b/dali/internal/trace/generic/trace-factory-generic.cpp similarity index 92% rename from dali/internal/trace/ubuntu/trace-factory-ubuntu.cpp rename to dali/internal/trace/generic/trace-factory-generic.cpp index 63b2592..844fc40 100644 --- a/dali/internal/trace/ubuntu/trace-factory-ubuntu.cpp +++ b/dali/internal/trace/generic/trace-factory-generic.cpp @@ -16,7 +16,7 @@ */ #include -#include +#include namespace Dali { diff --git a/dali/internal/trace/ubuntu/trace-manager-impl-ubuntu.cpp b/dali/internal/trace/generic/trace-manager-impl-generic.cpp similarity index 54% rename from dali/internal/trace/ubuntu/trace-manager-impl-ubuntu.cpp rename to dali/internal/trace/generic/trace-manager-impl-generic.cpp index c172c1a..45861a5 100644 --- a/dali/internal/trace/ubuntu/trace-manager-impl-ubuntu.cpp +++ b/dali/internal/trace/generic/trace-manager-impl-generic.cpp @@ -16,8 +16,8 @@ */ // EXTERNAL INCLUDES -#include #include +#include "trace-manager-impl-generic.h" // INTERNAL INCLUDES @@ -31,30 +31,30 @@ namespace Internal namespace Adaptor { -TraceManagerUbuntu* TraceManagerUbuntu::traceManagerUbuntu = nullptr; +TraceManagerGeneric* TraceManagerGeneric::traceManagerGeneric = nullptr; -TraceManagerUbuntu::TraceManagerUbuntu( PerformanceInterface* performanceInterface ) +TraceManagerGeneric::TraceManagerGeneric( PerformanceInterface* performanceInterface ) : TraceManager( performanceInterface ) { - TraceManagerUbuntu::traceManagerUbuntu = this; + TraceManagerGeneric::traceManagerGeneric = this; } -Dali::Integration::Trace::LogContextFunction TraceManagerUbuntu::GetLogContextFunction() +Dali::Integration::Trace::LogContextFunction TraceManagerGeneric::GetLogContextFunction() { return LogContext; } -void TraceManagerUbuntu::LogContext( bool start, const char* tag ) +void TraceManagerGeneric::LogContext( bool start, const char* tag ) { if( start ) { - unsigned short contextId = traceManagerUbuntu->mPerformanceInterface->AddContext( tag ); - traceManagerUbuntu->mPerformanceInterface->AddMarker( PerformanceInterface::START, contextId ); + unsigned short contextId = traceManagerGeneric->mPerformanceInterface->AddContext( tag ); + traceManagerGeneric->mPerformanceInterface->AddMarker( PerformanceInterface::START, contextId ); } else { - unsigned short contextId = traceManagerUbuntu->mPerformanceInterface->AddContext( tag ); - traceManagerUbuntu->mPerformanceInterface->AddMarker( PerformanceInterface::END, contextId ); + unsigned short contextId = traceManagerGeneric->mPerformanceInterface->AddContext( tag ); + traceManagerGeneric->mPerformanceInterface->AddMarker( PerformanceInterface::END, contextId ); } } diff --git a/dali/internal/trace/ubuntu/trace-manager-impl-ubuntu.h b/dali/internal/trace/generic/trace-manager-impl-generic.h similarity index 86% rename from dali/internal/trace/ubuntu/trace-manager-impl-ubuntu.h rename to dali/internal/trace/generic/trace-manager-impl-generic.h index 7590bdf..c9a755f 100644 --- a/dali/internal/trace/ubuntu/trace-manager-impl-ubuntu.h +++ b/dali/internal/trace/generic/trace-manager-impl-generic.h @@ -33,25 +33,25 @@ namespace Adaptor { class PerformanceInterface; -class TraceManagerUbuntu : public Dali::Internal::Adaptor::TraceManager +class TraceManagerGeneric : public Dali::Internal::Adaptor::TraceManager { public: /** * Static member to hold TraceManagerUbuntu instance. This allows * to access PerformanceInterface for network logging. */ - static TraceManagerUbuntu* traceManagerUbuntu; + static TraceManagerGeneric* traceManagerGeneric; /** * Explicit Constructor */ - explicit TraceManagerUbuntu( PerformanceInterface* performanceInterface ); + explicit TraceManagerGeneric( PerformanceInterface* performanceInterface ); protected: /** * Destructor */ - ~TraceManagerUbuntu() override = default; + ~TraceManagerGeneric() override = default; /** * Obtain the LogContextFunction method (Ubuntu specific) used for tracing