--- a/mmserv/tms/tmsserver/src/tmsserver.cpp Tue Aug 31 15:43:02 2010 +0300
+++ b/mmserv/tms/tmsserver/src/tmsserver.cpp Wed Sep 01 12:23:00 2010 +0100
@@ -18,7 +18,6 @@
#include <e32svr.h>
#include <e32uid.h>
#include <e32capability.h>
-#include <AudioPreference.h>
#include "tmsutility.h"
#include "tmsclientserver.h"
#include "tmstelephonycenrep.h"
@@ -30,10 +29,6 @@
#include "tmsglobaleffectssettings.h"
#include "tmstareventhandler.h"
#include "tmscenrepaudiohandler.h"
-#include "tmsdtmftoneplayer.h"
-#include "tmsdtmfprovider.h"
-#include "tmspubsublistener.h"
-#include "tmsrtparam.h"
#include "tmsserver.h"
using namespace TMS;
@@ -85,12 +80,7 @@
delete iEffectSettings;
delete iTarHandler;
delete iAudioCenRepHandler;
- DeinitRingTonePlayer();
- delete iTMSRtPlayer;
- delete iDTMFUplinkPlayer;
- delete iDTMFUplinkPlayerEtel;
- delete iDTMFDnlinkPlayer;
- delete iSyncVol;
+
TRACE_PRN_FN_EXT;
}
@@ -139,14 +129,6 @@
iTarHandler = NULL;
iAudioCenRepHandler = NULL;
iCurrentRouting = TMS_AUDIO_OUTPUT_PRIVATE;
- iDTMFDnlinkPlayer = NULL;
- iDTMFUplinkPlayer = NULL;
- iDTMFUplinkPlayerEtel = NULL;
- iActiveCallType = -1;
- iSyncVol = TMSPubSubListener::NewL(KTMSPropertyCategory,ESyncVolume, this);
-
- //TODO: EUnit fails to initialize ProfileEngine in RT in eshell mode
- TRAP_IGNORE(InitRingTonePlayerL());
// We need it running for global volume change updates
StartRoutingNotifierL();
@@ -198,6 +180,46 @@
}
// -----------------------------------------------------------------------------
+// TMSServer::SetDnLinkSession
+//
+// -----------------------------------------------------------------------------
+//
+void TMSServer::SetDnLinkSession(const TBool aSession)
+ {
+ iDnlinkSession = aSession;
+ }
+
+// -----------------------------------------------------------------------------
+// TMSServer::SetUpLinkSession
+//
+// -----------------------------------------------------------------------------
+//
+void TMSServer::SetUpLinkSession(const TBool aSession)
+ {
+ iUplinkSession = aSession;
+ }
+
+// -----------------------------------------------------------------------------
+// TMSServer::HasDnLinkSession
+//
+// -----------------------------------------------------------------------------
+//
+TBool TMSServer::HasDnLinkSession() const
+ {
+ return iDnlinkSession;
+ }
+
+// -----------------------------------------------------------------------------
+// TMSServer::HasUpLinkSession
+//
+// -----------------------------------------------------------------------------
+//
+TBool TMSServer::HasUpLinkSession() const
+ {
+ return iUplinkSession;
+ }
+
+// -----------------------------------------------------------------------------
// TMSServer::GetNewTMSCallSessionHandleL
//
// -----------------------------------------------------------------------------
@@ -240,7 +262,7 @@
TInt status = TMS_RESULT_SUCCESS;
TMSStartAndMonitorTMSCallThread* callServerThread = NULL;
- TRAP(status, callServerThread = TMSStartAndMonitorTMSCallThread::NewL(
+ TRAP(status, callServerThread =TMSStartAndMonitorTMSCallThread::NewL(
const_cast<TMSServer*>(this)));
if (status != TMS_RESULT_SUCCESS)
{
@@ -265,13 +287,11 @@
case TMS_AUDIO_OUTPUT_LOUDSPEAKER:
{
iEffectSettings->GetLoudSpkrVolume(volume);
- TRACE_PRN_N1(_L("loudspk vol %d"),volume);
}
break;
default:
{
iEffectSettings->GetEarPieceVolume(volume);
- TRACE_PRN_N1(_L("ear vol %d"),volume);
}
break;
}
@@ -544,11 +564,9 @@
case TMS_AUDIO_OUTPUT_PUBLIC:
case TMS_AUDIO_OUTPUT_LOUDSPEAKER:
iEffectSettings->GetLoudSpkrVolume(volume);
- TRACE_PRN_N1(_L("TMSServer::GetLevel loudspkr vol %d"),volume);
break;
default:
iEffectSettings->GetEarPieceVolume(volume);
- TRACE_PRN_N1(_L("TMSServer::GetLevel ear vol %d"),volume);
break;
}
@@ -606,12 +624,16 @@
}
iSessionIter.SetToFirst();
- TMSServerSession* ss = static_cast<TMSServerSession*> (iSessionIter++);
- while (ss != NULL)
+ TMSServerSession* serverSession =
+ static_cast<TMSServerSession*> (iSessionIter++);
+
+ while (serverSession != NULL)
{
- ss->HandleGlobalEffectChange(TMS_EVENT_EFFECT_VOL_CHANGED, level,
- EFalse, iCurrentRouting);
- ss = static_cast<TMSServerSession*> (iSessionIter++);
+ serverSession->HandleGlobalEffectChange(
+ TMS_EVENT_EFFECT_VOL_CHANGED, level, EFalse,
+ iCurrentRouting);
+
+ serverSession = static_cast<TMSServerSession*> (iSessionIter++);
}
}
@@ -678,11 +700,15 @@
iAudioCenRepHandler->SetMuteState(level);
iEffectSettings->SetGain(level);
iSessionIter.SetToFirst();
- TMSServerSession* ss = static_cast<TMSServerSession*> (iSessionIter++);
- while (ss != NULL)
+
+ TMSServerSession* serverSession =
+ static_cast<TMSServerSession*> (iSessionIter++);
+
+ while (serverSession != NULL)
{
- ss->HandleGlobalEffectChange(TMS_EVENT_EFFECT_GAIN_CHANGED, level);
- ss = static_cast<TMSServerSession*> (iSessionIter++);
+ serverSession->HandleGlobalEffectChange(
+ TMS_EVENT_EFFECT_GAIN_CHANGED, level);
+ serverSession = static_cast<TMSServerSession*> (iSessionIter++);
}
}
@@ -801,43 +827,32 @@
TRACE_PRN_FN_ENT;
TInt vol;
- TInt status(TMS_RESULT_SUCCESS);
- FindActiveCallType();
-
- if (iActiveCallType == TMS_CALL_CS)
+ iCurrentRouting = routingpckg().iOutput;
+ if (iCurrentRouting == TMS_AUDIO_OUTPUT_PUBLIC ||
+ iCurrentRouting == TMS_AUDIO_OUTPUT_LOUDSPEAKER)
{
-
- iCurrentRouting = routingpckg().iOutput;
- if (iCurrentRouting == TMS_AUDIO_OUTPUT_PUBLIC ||
- iCurrentRouting == TMS_AUDIO_OUTPUT_LOUDSPEAKER)
- {
- iEffectSettings->GetLoudSpkrVolume(vol);
- TRACE_PRN_N1(_L("TMSServer::NotifyTarClients loudspkr vol %d"),vol);
- }
- else
- {
- iEffectSettings->GetEarPieceVolume(vol);
- TRACE_PRN_N1(_L("TMSServer::NotifyTarClients ear vol %d"),vol);
- }
-
- status = SendMessageToCallServ(TMS_EFFECT_GLOBAL_VOL_SET, vol);
+ iEffectSettings->GetLoudSpkrVolume(vol);
+ }
+ else
+ {
+ iEffectSettings->GetEarPieceVolume(vol);
}
+ TInt status = SendMessageToCallServ(TMS_EFFECT_GLOBAL_VOL_SET, vol);
+
iSessionIter.SetToFirst();
- TMSServerSession* ss = static_cast<TMSServerSession*> (iSessionIter++);
- while (ss != NULL)
+ TMSServerSession* serverSession =
+ static_cast<TMSServerSession*> (iSessionIter++);
+ while (serverSession != NULL)
{
// Send only if there is a subscriber to TMS routing notifications.
if (iTarHandlerCount > 1)
{
- ss->HandleRoutingChange(routingpckg);
+ serverSession->HandleRoutingChange(routingpckg);
}
- if (iActiveCallType == TMS_CALL_CS)
- {
- ss->HandleGlobalEffectChange(TMS_EVENT_EFFECT_VOL_CHANGED, vol,
- ETrue, iCurrentRouting);
- }
- ss = static_cast<TMSServerSession*> (iSessionIter++);
+ serverSession->HandleGlobalEffectChange(TMS_EVENT_EFFECT_VOL_CHANGED,
+ vol, ETrue, iCurrentRouting);
+ serverSession = static_cast<TMSServerSession*> (iSessionIter++);
}
TRACE_PRN_FN_EXT;
@@ -845,603 +860,6 @@
}
// -----------------------------------------------------------------------------
-// TMSServer::InitDTMF
-//
-// -----------------------------------------------------------------------------
-//
-TInt TMSServer::InitDTMF(const RMessage2& aMessage)
- {
- TRACE_PRN_FN_ENT;
- TInt status(TMS_RESULT_SUCCESS);
- TMSStreamType strmtype;
- strmtype = (TMSStreamType) aMessage.Int0();
-
- if (strmtype == TMS_STREAM_UPLINK)
- {
- if (!iDTMFUplinkPlayerEtel) //CS call
- {
- // Uses ETel for uplink
- TRAP(status, iDTMFUplinkPlayerEtel = TMSDTMFProvider::NewL());
- if (iDTMFUplinkPlayerEtel && status == TMS_RESULT_SUCCESS)
- {
- iDTMFUplinkPlayerEtel->AddObserver(*this);
- }
- }
- if (!iDTMFUplinkPlayer) //IP call
- {
- TRAP(status, iDTMFUplinkPlayer = TMSAudioDtmfTonePlayer::NewL(*this,
- KAudioDTMFString, KAudioPriorityDTMFString));
- }
- }
- else if (strmtype == TMS_STREAM_DOWNLINK)
- {
- if (!iDTMFDnlinkPlayer) //CS or IP call
- {
- TRAP(status, iDTMFDnlinkPlayer = TMSAudioDtmfTonePlayer::NewL(*this,
- KAudioDTMFString, KAudioPriorityDTMFString));
- }
- }
-
- aMessage.Complete(status);
- TRACE_PRN_FN_EXT;
- return status;
- }
-
-// -----------------------------------------------------------------------------
-// TMSServer::StartDTMF
-//
-// -----------------------------------------------------------------------------
-//
-TInt TMSServer::StartDTMF(const RMessage2& aMessage)
- {
- TRACE_PRN_FN_ENT;
-
- TInt status(TMS_RESULT_SUCCESS);
- TInt len(0);
- TMSStreamType strmtype;
- strmtype = (TMSStreamType) aMessage.Int0();
- len = aMessage.GetDesLength(1);
- if (len > 0)
- {
- HBufC* tone(NULL);
- TRAP(status, tone = HBufC::NewL(len));
- if (status == TMS_RESULT_SUCCESS)
- {
- TPtr ptr = tone->Des();
- status = aMessage.Read(1, ptr);
- TRACE_PRN_N(ptr);
-
- if (strmtype == TMS_STREAM_UPLINK)
- {
-#ifdef __WINSCW__
- // Just to hear DTMF tones in Wins
- iActiveCallType = TMS_CALL_IP;
-#else
- FindActiveCallType();
-#endif
- if (iActiveCallType == TMS_CALL_IP && iDTMFUplinkPlayer)
- {
- iDTMFUplinkPlayer->PlayDtmfTone(ptr);
- status = TMS_RESULT_SUCCESS;
- }
- else if (iActiveCallType == TMS_CALL_CS &&
- iDTMFUplinkPlayerEtel)
- {
- status = iDTMFUplinkPlayerEtel->SendDtmfToneString(ptr);
- }
- else
- {
- status = TMS_RESULT_INVALID_STATE;
- }
- NotifyDtmfClients(ECmdDTMFToneUplPlayStarted, status);
- }
- else if (strmtype == TMS_STREAM_DOWNLINK)
- {
- status = TMS_RESULT_INVALID_STATE;
- if (iDTMFDnlinkPlayer)
- {
- iDTMFDnlinkPlayer->PlayDtmfTone(ptr);
- status = TMS_RESULT_SUCCESS;
- }
- NotifyDtmfClients(ECmdDTMFToneDnlPlayStarted, status);
- }
- else
- {
- status = TMS_RESULT_STREAM_TYPE_NOT_SUPPORTED;
- }
- }
- delete tone;
- tone = NULL;
- }
-
- aMessage.Complete(status);
- TRACE_PRN_FN_EXT;
- return status;
- }
-
-// -----------------------------------------------------------------------------
-// TMSServer::StopDTMF
-//
-// -----------------------------------------------------------------------------
-//
-TInt TMSServer::StopDTMF(const RMessage2& aMessage)
- {
- TRACE_PRN_FN_ENT;
-
- TInt status(TMS_RESULT_INVALID_STATE);
- TMSStreamType streamtype;
- streamtype = (TMSStreamType) aMessage.Int0();
-
- if (streamtype == TMS_STREAM_UPLINK)
- {
- if (iActiveCallType == TMS_CALL_IP && iDTMFUplinkPlayer)
- {
- iDTMFUplinkPlayer->Cancel();
- status = TMS_RESULT_SUCCESS;
- }
- else if (iActiveCallType == TMS_CALL_CS &&
- iDTMFUplinkPlayerEtel)
- {
- status = iDTMFUplinkPlayerEtel->StopDtmfTone();
- status = TMSUtility::EtelToTMSResult(status);
- }
- }
- else if (streamtype == TMS_STREAM_DOWNLINK)
- {
- if (iDTMFDnlinkPlayer)
- {
- iDTMFDnlinkPlayer->Cancel();
- status = TMS_RESULT_SUCCESS;
- }
- }
- iActiveCallType = -1;
- NotifyDtmfClients(ECmdDTMFTonePlayFinished, status);
- aMessage.Complete(status);
- TRACE_PRN_FN_EXT;
- return status;
- }
-
-// -----------------------------------------------------------------------------
-// TMSServer::ContinueSendingDTMF
-//
-// -----------------------------------------------------------------------------
-//
-TInt TMSServer::ContinueSendingDTMF(const RMessage2& aMessage)
- {
- TRACE_PRN_FN_ENT;
- TInt status(TMS_RESULT_INVALID_STATE);
- if (iActiveCallType == TMS_CALL_CS && iDTMFUplinkPlayerEtel)
- {
- TBool continuesnd = (TBool) aMessage.Int0();
- status = iDTMFUplinkPlayerEtel->ContinueDtmfStringSending(continuesnd);
- status = TMSUtility::EtelToTMSResult(status);
- }
- aMessage.Complete(status);
- TRACE_PRN_FN_EXT;
- return status;
- }
-
-// -----------------------------------------------------------------------------
-// TMSServer::NotifyDtmfClients
-//
-// -----------------------------------------------------------------------------
-//
-TInt TMSServer::NotifyDtmfClients(gint aEventType, gint aError)
- {
- TRACE_PRN_FN_ENT;
- iSessionIter.SetToFirst();
- TMSServerSession* ss = static_cast<TMSServerSession*> (iSessionIter++);
- while (ss != NULL)
- {
- ss->NotifyClient(aEventType, aError);
- ss = static_cast<TMSServerSession*> (iSessionIter++);
- }
- TRACE_PRN_FN_EXT;
- return TMS_RESULT_SUCCESS;
- }
-
-//From DTMFTonePlayerObserver
-// -----------------------------------------------------------------------------
-// TMSServer::DTMFInitCompleted
-//
-// -----------------------------------------------------------------------------
-//
-void TMSServer::DTMFInitCompleted(gint status)
- {
- TRACE_PRN_FN_ENT;
- if (status != TMS_RESULT_SUCCESS)
- {
- NotifyDtmfClients(ECmdDTMFTonePlayFinished, status);
- }
- TRACE_PRN_FN_EXT;
- }
-
-// -----------------------------------------------------------------------------
-// TMSServer::DTMFToneFinished
-//
-// -----------------------------------------------------------------------------
-//
-void TMSServer::DTMFToneFinished(gint status)
- {
- TRACE_PRN_FN_ENT;
- TRACE_PRN_IF_ERR(status);
-
- // KErrUnderflow indicates end of DTMF playback.
- if (status == KErrUnderflow /*|| status == KErrInUse*/)
- {
- status = TMS_RESULT_SUCCESS;
- }
- NotifyDtmfClients(ECmdDTMFTonePlayFinished, status);
- TRACE_PRN_FN_EXT;
- }
-
-// -----------------------------------------------------------------------------
-// TMSServer::FindActiveCallType
-//
-// -----------------------------------------------------------------------------
-//
-gint TMSServer::FindActiveCallType()
- {
- TInt status(TMS_RESULT_INVALID_STATE);
- iActiveCallType = -1;
- TInt i = 0;
- while (i < iTMSCallServList.Count())
- {
- TMSStartAndMonitorTMSCallThread* callThread = iTMSCallServList[i];
- if (callThread)
- {
- TmsCallMsgBufPckg pckg;
- TIpcArgs args(&pckg);
- status = callThread->iTMSCallProxyLocal.ReceiveFromCallServer(
- TMS_GET_ACTIVE_CALL_PARAMS, args);
- if (pckg().iBool || status != TMS_RESULT_SUCCESS)
- {
- iActiveCallType = static_cast<TMSCallType> (pckg().iInt);
- break;
- }
- }
- i++;
- }
- return status;
- }
-
-// -----------------------------------------------------------------------------
-// TMSServer::HandleDTMFEvent
-//
-// -----------------------------------------------------------------------------
-//
-void TMSServer::HandleDTMFEvent(const TMSDTMFObserver::TCCPDtmfEvent event,
- const gint status, const TChar /*tone*/)
- {
- TRACE_PRN_FN_ENT;
- TRACE_PRN_IF_ERR(status);
- gint cmd = ECmdDTMFTonePlayFinished;
-
- switch (event)
- {
- case ECCPDtmfUnknown: //Unknown
- break;
- case ECCPDtmfManualStart: //DTMF sending started manually
- case ECCPDtmfSequenceStart: //Automatic DTMF sending initialized
- cmd = ECmdDTMFToneUplPlayStarted;
- break;
- case ECCPDtmfManualStop: //DTMF sending stopped manually
- case ECCPDtmfManualAbort: //DTMF sending aborted manually
- case ECCPDtmfSequenceStop: //Automatic DTMF sending stopped
- case ECCPDtmfSequenceAbort: //Automatic DTMF sending aborted
- case ECCPDtmfStopInDtmfString: //There was stop mark in DTMF string
- case ECCPDtmfStringSendingCompleted://DTMF sending success
- default:
- break;
- }
-
- NotifyDtmfClients(cmd, status);
- TRACE_PRN_FN_EXT;
- }
-
-// -----------------------------------------------------------------------------
-// TMSServer::InitRingTonePlayerL
-//
-// -----------------------------------------------------------------------------
-//
-void TMSServer::InitRingTonePlayerL()
- {
- TRACE_PRN_FN_ENT;
-
- DeinitRingTonePlayer();
-
- if (!iTMSRtPlayer)
- {
- iTMSRtPlayer = TMSRingTonePlayer::NewL(*this);
- }
-
- TRACE_PRN_FN_EXT;
- }
-
-// -----------------------------------------------------------------------------
-// TMSServer::DeinitRingTonePlayer
-//
-// -----------------------------------------------------------------------------
-//
-void TMSServer::DeinitRingTonePlayer()
- {
- TRACE_PRN_FN_ENT;
-
- if (iTMSRtPlayer)
- {
- iTMSRtPlayer->DeinitRingTonePlayer();
- }
-
- delete iRtFile;
- iRtFile = NULL;
- delete iRtSequence;
- iRtSequence = NULL;
- delete iTtsText;
- iTtsText = NULL;
-
- TRACE_PRN_FN_EXT;
- }
-
-// -----------------------------------------------------------------------------
-// TMSServer::OpenRingTonePlayerFromFileL
-//
-// -----------------------------------------------------------------------------
-//
-void TMSServer::OpenRingTonePlayerFromFileL(const RMessage2& aMessage)
- {
- TRACE_PRN_FN_ENT;
-
- gint status(TMS_RESULT_INVALID_ARGUMENT);
- gint len = aMessage.GetDesLength(0);
- if (len > 0)
- {
- InitRingTonePlayerL();
-
- if (iTMSRtPlayer)
- {
- iRtFile = HBufC::NewL(len);
- TPtr ptr = iRtFile->Des();
- aMessage.ReadL(0, ptr);
- iTMSRtPlayer->CreateRingTonePlayerL(EPlayerAudio, *iRtFile);
- len = aMessage.GetDesLength(1);
- if (len > 0)
- {
- delete iTtsText;
- iTtsText = NULL;
- iTtsText = HBufC::NewL(len);
- TPtr ptr1 = iTtsText->Des();
- aMessage.ReadL(1, ptr1);
- iTMSRtPlayer->CreateTTSPlayerL(ptr1);
- }
- status = TMS_RESULT_SUCCESS;
- }
- }
- aMessage.Complete(status);
-
- TRACE_PRN_FN_EXT;
- }
-
-// -----------------------------------------------------------------------------
-// TMSServer::OpenRingTonePlayerFromProfileL
-//
-// -----------------------------------------------------------------------------
-//
-void TMSServer::OpenRingTonePlayerFromProfileL(const RMessage2& aMessage)
- {
- TRACE_PRN_FN_ENT;
-
- gint status(TMS_RESULT_INVALID_ARGUMENT);
- InitRingTonePlayerL();
-
- if (iTMSRtPlayer)
- {
- iTMSRtPlayer->CreateRingTonePlayerL(EPlayerDefault);
- gint len = aMessage.GetDesLength(1);
- if (len > 0)
- {
- delete iTtsText;
- iTtsText = NULL;
- iTtsText = HBufC::NewL(len);
- TPtr ptr = iTtsText->Des();
- aMessage.ReadL(1, ptr);
- iTMSRtPlayer->CreateTTSPlayerL(ptr);
- }
- status = TMS_RESULT_SUCCESS;
- }
- aMessage.Complete(status);
-
- TRACE_PRN_FN_EXT;
- }
-
-// -----------------------------------------------------------------------------
-// TMSServer::OpenRingToneSequencePlayerL
-//
-// -----------------------------------------------------------------------------
-//
-void TMSServer::OpenRingToneSequencePlayerL(const RMessage2& aMessage)
- {
- TRACE_PRN_FN_ENT;
-
- gint status(TMS_RESULT_INVALID_ARGUMENT);
- gint len = aMessage.GetDesLength(0);
- if (len > 0)
- {
- InitRingTonePlayerL();
- iRtSequence = HBufC8::NewL(len);
- TPtr8 ptr = iRtSequence->Des();
- aMessage.ReadL(0, ptr);
-
- if (iTMSRtPlayer)
- {
- iTMSRtPlayer->CreateCustomSequencePlayerL(ptr);
- status = TMS_RESULT_SUCCESS;
- }
- }
- aMessage.Complete(status);
-
- TRACE_PRN_FN_EXT;
- }
-
-// -----------------------------------------------------------------------------
-// TMSServer::OpenRingToneBeepOnceL
-//
-// -----------------------------------------------------------------------------
-//
-void TMSServer::OpenRingToneBeepOnceL()
- {
- TRACE_PRN_FN_ENT;
-
- InitRingTonePlayerL();
-
- if (iTMSRtPlayer)
- {
- iTMSRtPlayer->CreateSequencePlayerL(EPlayerBeepOnce);
- }
-
- TRACE_PRN_FN_EXT;
- }
-
-// -----------------------------------------------------------------------------
-// TMSServer::DeinitRingTone
-//
-// -----------------------------------------------------------------------------
-//
-void TMSServer::OpenRingToneSilentL()
- {
- TRACE_PRN_FN_ENT;
-
- InitRingTonePlayerL();
-
- if (iTMSRtPlayer)
- {
- iTMSRtPlayer->CreateSequencePlayerL(EPlayerSilent);
- }
-
- TRACE_PRN_FN_EXT;
- }
-
-// -----------------------------------------------------------------------------
-// TMSServer::OpenRingToneUnsecureVoipL
-//
-// -----------------------------------------------------------------------------
-//
-void TMSServer::OpenRingToneUnsecureVoipL()
- {
- TRACE_PRN_FN_ENT;
-
- InitRingTonePlayerL();
-
- if (iTMSRtPlayer)
- {
- iTMSRtPlayer->CreateSequencePlayerL(EPlayerUnsecureVoIP);
- }
-
- TRACE_PRN_FN_EXT;
- }
-
-// -----------------------------------------------------------------------------
-// TMSServer::PlayRingToneL
-//
-// -----------------------------------------------------------------------------
-//
-void TMSServer::PlayRingToneL()
- {
- TRACE_PRN_FN_ENT;
-
- if (iTMSRtPlayer)
- {
- iTMSRtPlayer->PlayRingToneL();
- }
- else
- {
- User::Leave(TMS_RESULT_UNINITIALIZED_OBJECT);
- }
-
- TRACE_PRN_FN_EXT;
- }
-
-// -----------------------------------------------------------------------------
-// TMSServer::PauseVideoRingTone
-//
-// -----------------------------------------------------------------------------
-//
-void TMSServer::PauseVideoRingTone()
- {
- StopRingTone();
- }
-
-// -----------------------------------------------------------------------------
-// TMSServer::StopRingTone
-//
-// -----------------------------------------------------------------------------
-//
-void TMSServer::StopRingTone()
- {
- TRACE_PRN_FN_ENT;
-
- if (iTMSRtPlayer)
- {
- iTMSRtPlayer->StopPlaying();
- }
-
- TRACE_PRN_FN_EXT;
- }
-
-// -----------------------------------------------------------------------------
-// TMSServer::MuteRingTone
-//
-// -----------------------------------------------------------------------------
-//
-void TMSServer::MuteRingTone()
- {
- TRACE_PRN_FN_ENT;
-
- if (iTMSRtPlayer)
- {
- iTMSRtPlayer->MuteRingTone();
- }
-
- TRACE_PRN_FN_EXT;
- }
-
-// -----------------------------------------------------------------------------
-// TMSServer::RtPlayerEvent
-//
-// -----------------------------------------------------------------------------
-//
-void TMSServer::RtPlayerEvent(gint aEventType, gint aError)
- {
- TRACE_PRN_FN_ENT;
-
- iSessionIter.SetToFirst();
- TMSServerSession* ss = static_cast<TMSServerSession*> (iSessionIter++);
-
- while (ss != NULL)
- {
- ss->NotifyClient(aEventType, aError);
- ss = static_cast<TMSServerSession*> (iSessionIter++);
- }
-
- TRACE_PRN_FN_EXT;
- }
-
-// -----------------------------------------------------------------------------
-// TMSServer::HandleNotifyPSL
-//
-// -----------------------------------------------------------------------------
-//
-void TMSServer::HandleNotifyPSL(const TUid aUid, const TInt& aKey,
- const TRequestStatus& aStatus)
- {
- TRACE_PRN_FN_ENT;
- if(iEffectSettings)
- {
- iEffectSettings->ResetDefaultVolume();
- }
- TRACE_PRN_FN_EXT;
- }
-
-// -----------------------------------------------------------------------------
// TMSServer::RunServerL
//
// -----------------------------------------------------------------------------
@@ -1725,3 +1143,4 @@
return r;
}
+// End of file