diff -r 630d2f34d719 -r 07a122eea281 telephonyutils/telephonywatchers/src/signalstrengthwatcher.cpp --- a/telephonyutils/telephonywatchers/src/signalstrengthwatcher.cpp Tue Aug 31 16:23:08 2010 +0300 +++ b/telephonyutils/telephonywatchers/src/signalstrengthwatcher.cpp Wed Sep 01 12:40:21 2010 +0100 @@ -1,4 +1,4 @@ -// Copyright (c) 2000-2010 Nokia Corporation and/or its subsidiary(-ies). +// Copyright (c) 2000-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" @@ -16,13 +16,7 @@ // // User includes - - -#include "OstTraceDefinitions.h" -#ifdef OST_TRACE_COMPILER_IN_USE -#include "signalstrengthwatcherTraces.h" -#endif - +#include "watcherlog.h" #include "signalstrengthwatcher.h" // System includes @@ -85,7 +79,7 @@ { case ESignalStrengthNotYetInitialised: case ESignalStrengthStateRequestInitialSignalStrength: - OstTraceDef0(OST_TRACE_CATEGORY_DEBUG, TRACE_INTERNALS, CSIGNALSTRENGTHWATCHER_HANDLEPHONESTATEEVENTL_1, "SignalStrengthWatcher : Requesting initial signal strength"); + LOGSIGNAL1("SignalStrengthWatcher : Requesting initial signal strength"); Phone().GetSignalStrength(iStatus, iSignalStrength, iSignalBars); SignalStrengthState() = ESignalStrengthWaitingForInitialSignalStrength; SetActive(); @@ -136,10 +130,10 @@ void CSignalStrengthWatcher::HandleSignalStrengthUpdateL(TInt aCompletionCode) { - OstTraceDef0(OST_TRACE_CATEGORY_DEBUG, TRACE_INTERNALS, CSIGNALSTRENGTHWATCHER_HANDLESIGNALSTRENGTHUPDATEL_1, "SignalStrengthNotifier : Handling signal strength update"); + LOGSIGNAL1("SignalStrengthNotifier : Handling signal strength update"); if (aCompletionCode < KErrNone) { - OstTraceDef1(OST_TRACE_CATEGORY_DEBUG, TRACE_INTERNALS, CSIGNALSTRENGTHWATCHER_HANDLESIGNALSTRENGTHUPDATEL_2, "SignalStrengthNotifier : Handling request error (%d)", aCompletionCode); + LOGSIGNAL2("SignalStrengthNotifier : Handling request error (%d)", aCompletionCode); // Indicate we don't know what the signal strength is TInt ret = iNetworkStrengthProperty.Set(ESANetworkStrengthUnknown); @@ -183,8 +177,8 @@ } else { - OstTraceDef1(OST_TRACE_CATEGORY_DEBUG, TRACE_INTERNALS, CSIGNALSTRENGTHWATCHER_HANDLESIGNALSTRENGTHUPDATEL_3, "SignalStrengthNotifier : Signal strength is: %d", (TInt) iSignalStrength); - OstTraceDef1(OST_TRACE_CATEGORY_DEBUG, TRACE_INTERNALS, CSIGNALSTRENGTHWATCHER_HANDLESIGNALSTRENGTHUPDATEL_4, "SignalStrengthNotifier : Signal bars is: %d", iSignalBars); + LOGSIGNAL2("SignalStrengthNotifier : Signal strength is: %d", (TInt) iSignalStrength); + LOGSIGNAL2("SignalStrengthNotifier : Signal bars is: %d", iSignalBars); // What is the signal strength now? TInt newState = ESANetworkStrengthUnknown; @@ -199,12 +193,12 @@ newState = ESANetworkStrengthHigh; // Update properties - OstTraceDef0(OST_TRACE_CATEGORY_DEBUG, TRACE_INTERNALS, CSIGNALSTRENGTHWATCHER_HANDLESIGNALSTRENGTHUPDATEL_5, "SignalStrengthNotifier : Informing properties of signal strength change"); + LOGSIGNAL1("SignalStrengthNotifier : Informing properties of signal strength change"); TInt ret = iNetworkStrengthProperty.Set(newState); if (!(ret == KErrNone || ret == KErrNotFound)) User::Leave(ret); - OstTraceDef0(OST_TRACE_CATEGORY_DEBUG, TRACE_INTERNALS, CSIGNALSTRENGTHWATCHER_HANDLESIGNALSTRENGTHUPDATEL_6, "SignalStrengthNotifier : Requesting signal strength change notification"); + LOGSIGNAL1("SignalStrengthNotifier : Requesting signal strength change notification"); Phone().NotifySignalStrengthChange(iStatus, iSignalStrength, iSignalBars); SetActive(); }