diff -r f92a4f87e424 -r 012cc2ee6408 usbmgmt/usbmgr/host/fdf/production/server/src/event.cpp --- a/usbmgmt/usbmgr/host/fdf/production/server/src/event.cpp Tue Aug 31 17:01:47 2010 +0300 +++ b/usbmgmt/usbmgr/host/fdf/production/server/src/event.cpp Wed Sep 01 12:35:00 2010 +0100 @@ -1,5 +1,5 @@ /* -* Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies). +* Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies). * All rights reserved. * This component and the accompanying materials are made available * under the terms of "Eclipse Public License v1.0" @@ -15,46 +15,45 @@ * */ +#include "event.h" #include -#include "event.h" -#include "OstTraceDefinitions.h" -#ifdef OST_TRACE_COMPILER_IN_USE -#include "eventTraces.h" + +#ifdef __FLOG_ACTIVE +_LIT8(KLogComponent, "fdf "); #endif - TDeviceEvent::TDeviceEvent() { - OstTraceFunctionEntry0( TDEVICEEVENT_TDEVICEEVENT_CONS_ENTRY ); - } + LOG_FUNC + } TDeviceEvent::~TDeviceEvent() { - OstTraceFunctionEntry0( TDEVICEEVENT_TDEVICEEVENT_DES_ENTRY ); + LOG_FUNC } +#ifdef __FLOG_ACTIVE + void TDeviceEvent::Log() const { - OstTrace1( TRACE_DUMP, TDEVICEEVENT_LOG, "\tLogging event 0x%08x", this ); - OstTrace1( TRACE_DUMP, TDEVICEEVENT_LOG_DUP1, "\t\tdevice ID = %d", iInfo.iDeviceId ); - OstTrace1( TRACE_DUMP, TDEVICEEVENT_LOG_DUP2, "\t\tevent type = %d", iInfo.iEventType ); - + LOGTEXT2(_L8("\tLogging event 0x%08x"), this); + LOGTEXT2(_L8("\t\tdevice ID = %d"), iInfo.iDeviceId); + LOGTEXT2(_L8("\t\tevent type = %d"), iInfo.iEventType); + switch ( iInfo.iEventType ) { case EDeviceAttachment: - OstTrace1( TRACE_DUMP, TDEVICEEVENT_LOG_DUP3, "\t\terror = %d", iInfo.iError ); - - if ( !iInfo.iError ) + LOGTEXT2(_L8("\t\terror = %d"), iInfo.iError); + if ( !iInfo.iError ) { - OstTrace1( TRACE_DUMP, TDEVICEEVENT_LOG_DUP4, "\t\tVID = 0x%04x", iInfo.iVid ); - OstTrace1( TRACE_DUMP, TDEVICEEVENT_LOG_DUP5, "\t\tPID = 0x%04x", iInfo.iPid ); + LOGTEXT2(_L8("\t\tVID = 0x%04x"), iInfo.iVid); + LOGTEXT2(_L8("\t\tPID = 0x%04x"), iInfo.iPid); } break; case EDriverLoad: - OstTrace1( TRACE_DUMP, TDEVICEEVENT_LOG_DUP6, "\t\terror = %d", iInfo.iError ); - OstTrace1( TRACE_DUMP, TDEVICEEVENT_LOG_DUP7, "\t\t\tdriver load status = %d", iInfo.iDriverLoadStatus); - + LOGTEXT2(_L8("\t\terror = %d"), iInfo.iError); + LOGTEXT2(_L8("\t\t\tdriver load status = %d"), iInfo.iDriverLoadStatus); break; case EDeviceDetachment: // No break deliberate. @@ -63,3 +62,4 @@ } } +#endif // __FLOG_ACTIVE