|
1 /* |
|
2 * Copyright (c) 2006 Nokia Corporation and/or its subsidiary(-ies). |
|
3 * All rights reserved. |
|
4 * This component and the accompanying materials are made available |
|
5 * under the terms of "Eclipse Public License v1.0" |
|
6 * which accompanies this distribution, and is available |
|
7 * at the URL "http://www.eclipse.org/legal/epl-v10.html". |
|
8 * |
|
9 * Initial Contributors: |
|
10 * Nokia Corporation - initial contribution. |
|
11 * |
|
12 * Contributors: |
|
13 * |
|
14 * Description: TelephonyAudioRoutingServer implementation |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 |
|
20 #include <e32svr.h> |
|
21 #include <e32math.h> |
|
22 #include <data_caging_path_literals.hrh> |
|
23 #include <barsc.h> |
|
24 #include <barsread.h> |
|
25 #include "TelephonyAudioRoutingServer.h" |
|
26 #include "TelephonyAudioRoutingServerSession.h" |
|
27 #include "TelephonyAudioRoutingClientServer.h" |
|
28 |
|
29 |
|
30 void PanicClient( |
|
31 const RMessage2& aMessage, |
|
32 TTelephonyAudioRoutingPanic aPanic) |
|
33 { |
|
34 _LIT(KPanic,"TelephonyAudioRoutingServer"); |
|
35 aMessage.Panic(KPanic,aPanic); |
|
36 } |
|
37 |
|
38 // ========================== OTHER EXPORTED FUNCTIONS ========================= |
|
39 |
|
40 // ----------------------------------------------------------------------------- |
|
41 // StartThreadL |
|
42 // Start the TelephonyAudioRoutingServer thread. |
|
43 // Returns: TInt: error code |
|
44 // ----------------------------------------------------------------------------- |
|
45 // |
|
46 EXPORT_C TInt CTelephonyAudioRoutingServer::StartThreadL( |
|
47 TAny* /*aParms*/) |
|
48 /** |
|
49 Thread entry-point function. |
|
50 The TServerStart objects is passed as the thread parameter |
|
51 **/ |
|
52 { |
|
53 |
|
54 TELAUDRTNG_RDEBUG(_L("[TELAUDRTNG]\t CTelephonyAudioRoutingServer::StartThreadL ")); |
|
55 |
|
56 TInt err = KErrNone; |
|
57 __UHEAP_MARK; |
|
58 |
|
59 CTrapCleanup* cleanup = CTrapCleanup::New(); |
|
60 |
|
61 if (!cleanup) |
|
62 err = KErrNoMemory; |
|
63 |
|
64 if (!err) |
|
65 { |
|
66 CActiveScheduler* sched=NULL; |
|
67 sched=new(ELeave) CActiveScheduler; |
|
68 CActiveScheduler::Install(sched); |
|
69 CTelephonyAudioRoutingServer* server = NULL; |
|
70 TRAPD(err,server = CTelephonyAudioRoutingServer::NewL()); |
|
71 |
|
72 if(!err) |
|
73 { |
|
74 // Sync with the client and enter the active scheduler |
|
75 RThread::Rendezvous(KErrNone); |
|
76 sched->Start(); |
|
77 } |
|
78 |
|
79 delete server; |
|
80 delete sched; |
|
81 } |
|
82 |
|
83 delete cleanup; |
|
84 |
|
85 __UHEAP_MARKEND; |
|
86 return err; |
|
87 } |
|
88 |
|
89 |
|
90 // ============================ MEMBER FUNCTIONS =============================== |
|
91 |
|
92 // ----------------------------------------------------------------------------- |
|
93 // CTelephonyAudioRoutingServer::CTelephonyAudioRoutingServer |
|
94 // C++ default constructor can NOT contain any code, that |
|
95 // might leave. |
|
96 // ----------------------------------------------------------------------------- |
|
97 // |
|
98 CTelephonyAudioRoutingServer::CTelephonyAudioRoutingServer() |
|
99 :CServer2(0,EUnsharableSessions), |
|
100 iSessionIdsInUse() |
|
101 { |
|
102 iSessionCount = 0; |
|
103 } |
|
104 |
|
105 // ----------------------------------------------------------------------------- |
|
106 // CTelephonyAudioRoutingServer::ConstructL |
|
107 // Symbian 2nd phase constructor can leave. |
|
108 // ----------------------------------------------------------------------------- |
|
109 // |
|
110 void CTelephonyAudioRoutingServer::ConstructL() |
|
111 { |
|
112 TELAUDRTNG_RDEBUG(_L("[TELAUDRTNG]\t CTelephonyAudioRoutingServer::ConstructL ")); |
|
113 TName name(RThread().Name()); |
|
114 StartL(name); |
|
115 |
|
116 // Set default values |
|
117 iCurrentAudioOutput = CTelephonyAudioRouting::ENotActive; |
|
118 iPreviousAudioOutput = CTelephonyAudioRouting::ENotActive; |
|
119 } |
|
120 |
|
121 // ----------------------------------------------------------------------------- |
|
122 // CTelephonyAudioRoutingServer::NewL |
|
123 // Two-phased constructor. |
|
124 // ----------------------------------------------------------------------------- |
|
125 // |
|
126 EXPORT_C CTelephonyAudioRoutingServer* CTelephonyAudioRoutingServer::NewL() |
|
127 { |
|
128 CTelephonyAudioRoutingServer* self=new(ELeave) CTelephonyAudioRoutingServer(); |
|
129 CleanupStack::PushL(self); |
|
130 self->ConstructL(); |
|
131 CleanupStack::Pop(); |
|
132 return self; |
|
133 } |
|
134 |
|
135 // Destructor |
|
136 CTelephonyAudioRoutingServer::~CTelephonyAudioRoutingServer() |
|
137 { |
|
138 TELAUDRTNG_RDEBUG(_L("[TELAUDRTNG]\t CTelephonyAudioRoutingServer::~CTelephonyAudioRoutingServer ")); |
|
139 iSessionIdsInUse.Close(); |
|
140 iSetOutputRequests.Close(); |
|
141 iAvailableOutputs.Close(); |
|
142 } |
|
143 |
|
144 |
|
145 // ----------------------------------------------------------------------------- |
|
146 // CTelephonyAudioRoutingServer::NewSessionL |
|
147 // Create a new client session |
|
148 // (other items were commented in a header). |
|
149 // ----------------------------------------------------------------------------- |
|
150 // |
|
151 CSession2* CTelephonyAudioRoutingServer::NewSessionL( |
|
152 const TVersion&, |
|
153 const RMessage2& /*aMessage*/) const |
|
154 { |
|
155 TELAUDRTNG_RDEBUG(_L("[TELAUDRTNG]\t CTelephonyAudioRoutingServer::NewSessionL ")); |
|
156 |
|
157 CTelephonyAudioRoutingServer& nonConstThis = *const_cast<CTelephonyAudioRoutingServer*>(this); |
|
158 const TInt sessionId = nonConstThis.IdentifyAndAllocateNextFreeSessionIdL(); |
|
159 return new (ELeave) CTelephonyAudioRoutingServerSession(sessionId); |
|
160 } |
|
161 |
|
162 // ----------------------------------------------------------------------------- |
|
163 // CTelephonyAudioRoutingServer::DoSetOutputL |
|
164 // Notify the policy session about a request to change output. |
|
165 // (other items were commented in a header). |
|
166 // ----------------------------------------------------------------------------- |
|
167 // |
|
168 void CTelephonyAudioRoutingServer::DoSetOutputL ( |
|
169 TInt aSessionId, |
|
170 const RMessage2& aMessage) |
|
171 { |
|
172 |
|
173 TELAUDRTNG_RDEBUG(_L("[TELAUDRTNG]\t CTelephonyAudioRoutingServer::DoSetOutputL ")); |
|
174 |
|
175 //Check for multimedia capability: |
|
176 RThread clientThread; |
|
177 aMessage.ClientL(clientThread); |
|
178 RProcess clientProcess; |
|
179 User::LeaveIfError(clientThread.Process(clientProcess)); |
|
180 |
|
181 TProcessId clientProcessID(clientProcess.Id()); |
|
182 |
|
183 |
|
184 TBool clientHasCapabilities = clientProcess.HasCapability(ECapabilityMultimediaDD, KSuppressPlatSecDiagnostic); |
|
185 |
|
186 if (!clientHasCapabilities) |
|
187 { |
|
188 TELAUDRTNG_RDEBUG(_L("[TELAUDRTNG]\t CTelephonyAudioRoutingServer::DoSetOutputL ERROR: Client failed Capability Check")); |
|
189 aMessage.Complete(KErrPermissionDenied); |
|
190 return; |
|
191 } |
|
192 |
|
193 clientThread.Close(); |
|
194 clientProcess.Close(); |
|
195 |
|
196 TPckgBuf<CTelephonyAudioRouting::TAudioOutput> xPackage; |
|
197 aMessage.ReadL( 0, xPackage); |
|
198 |
|
199 CTelephonyAudioRouting::TAudioOutput response = xPackage(); |
|
200 TELAUDRTNG_RDEBUG1(_L("[TELAUDRTNG]\t CTelephonyAudioRoutingServer::DoSetOutputL Audio Output Value to set on the sessions: %d"), response); |
|
201 TPckgBuf<CTelephonyAudioRouting::TAudioOutput> yPackage; // space for previous output |
|
202 aMessage.ReadL( 1, yPackage); |
|
203 |
|
204 TPckgBuf<TInt> zPackage; // space for err |
|
205 aMessage.ReadL( 2, zPackage); |
|
206 |
|
207 TPckgBuf<TBool> showNotePkg; |
|
208 aMessage.ReadL(3, showNotePkg); |
|
209 iShowNoteMode = showNotePkg(); |
|
210 TELAUDRTNG_RDEBUG1(_L("[TELAUDRTNG]\t CTelephonyAudioRoutingServer::DoSetOutputL ShowNoteMode Value Sent to server = %d"), iShowNoteMode); |
|
211 |
|
212 iSetOutputRequests.Append(aSessionId); |
|
213 |
|
214 // Verify requested audio change exists in available outputs (unless is ENone or ENotActive) |
|
215 if ( (response != CTelephonyAudioRouting::ENone) && (response != CTelephonyAudioRouting::ENotActive)) |
|
216 { |
|
217 TBool found = IsAvailableOutput(response); |
|
218 if (!found) |
|
219 { |
|
220 TELAUDRTNG_RDEBUG(_L("[TELAUDRTNG]\t CTelephonyAudioRoutingServer::DoSetOutputL: ERROR, Requested output not in availableOutputs!")); |
|
221 SetOutputCompleteL(response, KErrPermissionDenied); |
|
222 return; |
|
223 } |
|
224 } |
|
225 |
|
226 iSessionIter.SetToFirst(); |
|
227 |
|
228 CTelephonyAudioRoutingServerSession* serverSession = static_cast<CTelephonyAudioRoutingServerSession*>(iSessionIter++); |
|
229 |
|
230 while (serverSession != NULL) |
|
231 { |
|
232 if(serverSession->SessionId() == iPolicySessionId) |
|
233 { |
|
234 serverSession->OutputChangeRequested(response); |
|
235 break; |
|
236 } |
|
237 serverSession = static_cast<CTelephonyAudioRoutingServerSession*>(iSessionIter++); |
|
238 } |
|
239 |
|
240 } |
|
241 |
|
242 // ----------------------------------------------------------------------------- |
|
243 // CTelephonyAudioRoutingServer::IdentifyAndAllocateNextFreeSessionIdL |
|
244 // Assign a unique session Id to a new session |
|
245 // (other items were commented in a header). |
|
246 // ----------------------------------------------------------------------------- |
|
247 // |
|
248 TInt CTelephonyAudioRoutingServer::IdentifyAndAllocateNextFreeSessionIdL() |
|
249 { |
|
250 |
|
251 TELAUDRTNG_RDEBUG(_L("[TELAUDRTNG]\t CTelephonyAudioRoutingServer::IdentifyAndAllocateNextFreeSessionIdL ")); |
|
252 |
|
253 // The aim of this method is to locate a session identifier which is not already |
|
254 // in use.... |
|
255 TInt sessionId = 0; |
|
256 TInt errorOrIndex; |
|
257 |
|
258 // Only 256 (KMaxNumberOfSessions) are allowed |
|
259 const TInt numberOfUsedSessionIds = iSessionIdsInUse.Count(); |
|
260 if (numberOfUsedSessionIds > KMaxNumberOfSessions) |
|
261 { |
|
262 User::LeaveIfError(KErrDied); |
|
263 } |
|
264 |
|
265 // Session Id's indexing begins at 1, not 0 |
|
266 for (TInt count = 1; count < KMaxNumberOfSessions+1; count++) |
|
267 { |
|
268 sessionId = count; |
|
269 errorOrIndex = iSessionIdsInUse.FindInOrder(sessionId); |
|
270 |
|
271 // If sessionId=count not currently being used, assign it. |
|
272 // Save the session in the array of allocated ids. We use InsertInOrder |
|
273 // since it effectively allows a binary search when trying to find |
|
274 // free ids: |
|
275 if (errorOrIndex == KErrNotFound) |
|
276 { |
|
277 errorOrIndex = iSessionIdsInUse.InsertInOrder(sessionId); |
|
278 if (errorOrIndex < 0) // Handle error |
|
279 { |
|
280 User::LeaveIfError(KErrDied); |
|
281 } |
|
282 break; |
|
283 } |
|
284 |
|
285 // Prevent value returned by RArray<T>::FindInOrder from being propagated |
|
286 // to the client side in response to a RSessionBase::Connect() request. |
|
287 if ((errorOrIndex != KErrNotFound) && (errorOrIndex < 0)) |
|
288 { |
|
289 User::LeaveIfError(KErrDied); |
|
290 } |
|
291 |
|
292 } // End for |
|
293 |
|
294 return sessionId; |
|
295 |
|
296 } |
|
297 |
|
298 // ----------------------------------------------------------------------------- |
|
299 // CTelephonyAudioRoutingServer::AddSession |
|
300 // Add a new Session. |
|
301 // (other items were commented in a header). |
|
302 // ----------------------------------------------------------------------------- |
|
303 // |
|
304 void CTelephonyAudioRoutingServer::AddSession() |
|
305 { |
|
306 TELAUDRTNG_RDEBUG(_L("[TELAUDRTNG]\t CTelephonyAudioRoutingServer::AddSession ")); |
|
307 iSessionCount++; |
|
308 } |
|
309 |
|
310 // ----------------------------------------------------------------------------- |
|
311 // CTelephonyAudioRoutingServer::RemoveSession |
|
312 // Remove an existing session. |
|
313 // (other items were commented in a header). |
|
314 // ----------------------------------------------------------------------------- |
|
315 // |
|
316 void CTelephonyAudioRoutingServer::RemoveSession( |
|
317 TInt aSessionId) |
|
318 { |
|
319 TELAUDRTNG_RDEBUG(_L("[TELAUDRTNG]\t CTelephonyAudioRoutingServer::RemoveSession")); |
|
320 FreeSessionId(aSessionId); |
|
321 iSessionCount--; |
|
322 } |
|
323 |
|
324 // ----------------------------------------------------------------------------- |
|
325 // CTelephonyAudioRoutingServer::FreeSessionId |
|
326 // Free the session Id or a delated session for re-use. |
|
327 // (other items were commented in a header). |
|
328 // ----------------------------------------------------------------------------- |
|
329 // |
|
330 void CTelephonyAudioRoutingServer::FreeSessionId( |
|
331 TInt aSessionId) |
|
332 { |
|
333 |
|
334 TELAUDRTNG_RDEBUG1(_L("[TELAUDRTNG]\t CTelephonyAudioRoutingServer::FreeSessionId: ID: %d"), aSessionId); |
|
335 |
|
336 const TInt indexOrError = iSessionIdsInUse.FindInOrder(aSessionId); |
|
337 |
|
338 if (indexOrError >= 0) |
|
339 { |
|
340 // This session id can now be reused... |
|
341 iSessionIdsInUse.Remove(indexOrError); |
|
342 } |
|
343 } |
|
344 |
|
345 // ----------------------------------------------------------------------------- |
|
346 // CTelephonyAudioRoutingServer::SetPolicySessionId |
|
347 // Set the Id of the policy session. |
|
348 // (other items were commented in a header). |
|
349 // ----------------------------------------------------------------------------- |
|
350 // |
|
351 void CTelephonyAudioRoutingServer::SetPolicySessionId( |
|
352 TInt aSessionId) |
|
353 { |
|
354 iPolicySessionId = aSessionId; |
|
355 } |
|
356 |
|
357 // ----------------------------------------------------------------------------- |
|
358 // CTelephonyAudioRoutingServer::AvailableOutputsChangedL |
|
359 // Used by policy session to indicated to all other sessions that available outputs have changed. |
|
360 // (other items were commented in a header). |
|
361 // ----------------------------------------------------------------------------- |
|
362 // |
|
363 void CTelephonyAudioRoutingServer::AvailableOutputsChangedL( |
|
364 const TArray<CTelephonyAudioRouting::TAudioOutput>& aOutputs) |
|
365 { |
|
366 |
|
367 TELAUDRTNG_RDEBUG(_L("[TELAUDRTNG]\t CTelephonyAudioRoutingServer::AvailableOutputsChangedL ")); |
|
368 |
|
369 iAvailableOutputs.Reset(); |
|
370 TInt count = aOutputs.Count(); |
|
371 TELAUDRTNG_RDEBUG1(_L("[TELAUDRTNG]\t AvailableOutputsChangedL: Count = %d "),count); |
|
372 for(TInt i = 0; i < count; i++) |
|
373 { |
|
374 TELAUDRTNG_RDEBUG1(_L("[TELAUDRTNG]\t AvailableOutputsChangedL: aOutputs[i] = %d "),aOutputs[i]); |
|
375 iAvailableOutputs.AppendL(aOutputs[i]); |
|
376 } |
|
377 |
|
378 iSessionIter.SetToFirst(); |
|
379 |
|
380 CTelephonyAudioRoutingServerSession* serverSession = static_cast<CTelephonyAudioRoutingServerSession*>(iSessionIter++); |
|
381 while (serverSession != NULL) |
|
382 { |
|
383 if(serverSession->SessionId() != iPolicySessionId) |
|
384 serverSession->AvailableOutputsChanged(aOutputs); |
|
385 serverSession = static_cast<CTelephonyAudioRoutingServerSession*>(iSessionIter++); |
|
386 } |
|
387 |
|
388 } |
|
389 |
|
390 // ----------------------------------------------------------------------------- |
|
391 // CTelephonyAudioRoutingServer::SetOutputComplete |
|
392 // Used by policy session to indicate the session that requested a SetOutput() that |
|
393 // the request is complete, all the other session get OutputChanged() notification |
|
394 // (other items were commented in a header). |
|
395 // ----------------------------------------------------------------------------- |
|
396 // |
|
397 void CTelephonyAudioRoutingServer::SetOutputCompleteL( |
|
398 CTelephonyAudioRouting::TAudioOutput aOutput, |
|
399 TInt aError) |
|
400 { |
|
401 |
|
402 CTelephonyAudioRouting::TAudioOutput output = aOutput; |
|
403 |
|
404 TELAUDRTNG_RDEBUG1(_L("[TELAUDRTNG]\t CTelephonyAudioRoutingServer::SetOutputComplete called with: = %d"), output); |
|
405 |
|
406 TInt requestCount = iSetOutputRequests.Count(); |
|
407 |
|
408 if(requestCount>0) |
|
409 { |
|
410 |
|
411 TInt sessionToAlert = iSetOutputRequests[0]; |
|
412 iSessionIter.SetToFirst(); |
|
413 |
|
414 CTelephonyAudioRoutingServerSession* serverSession = static_cast<CTelephonyAudioRoutingServerSession*>(iSessionIter++); |
|
415 while (serverSession != NULL) |
|
416 { |
|
417 if(serverSession->SessionId() != iPolicySessionId) |
|
418 { |
|
419 |
|
420 if (serverSession->SessionId() == sessionToAlert ) |
|
421 { |
|
422 TELAUDRTNG_RDEBUG1(_L("[TELAUDRTNG]\t CTelephonyAudioRoutingServer::SetOutputComplete: Calling serverSession::SetOutputComplete with showNote: %d"), iShowNoteMode); |
|
423 serverSession->SetOutputComplete(output, aError, iShowNoteMode); |
|
424 } |
|
425 else |
|
426 { |
|
427 if (aError == KErrNone) |
|
428 { |
|
429 serverSession->OutputChanged(output, iShowNoteMode); |
|
430 } |
|
431 |
|
432 } |
|
433 } |
|
434 |
|
435 serverSession = static_cast<CTelephonyAudioRoutingServerSession*>(iSessionIter++); |
|
436 } |
|
437 |
|
438 for(TInt i=0;i<iSetOutputRequests.Count()-1;i++) |
|
439 { |
|
440 iSetOutputRequests[i] = iSetOutputRequests[i+1]; |
|
441 } |
|
442 iSetOutputRequests.Remove(iSetOutputRequests.Count()-1); |
|
443 } |
|
444 } |
|
445 |
|
446 // ----------------------------------------------------------------------------- |
|
447 // CTelephonyAudioRoutingServer::OutputChanged |
|
448 // Used by policy session to notify all sessions that the output has changed (from the policy side) |
|
449 // (other items were commented in a header). |
|
450 // ----------------------------------------------------------------------------- |
|
451 // |
|
452 void CTelephonyAudioRoutingServer::OutputChanged( |
|
453 CTelephonyAudioRouting::TAudioOutput aOutput) |
|
454 { |
|
455 |
|
456 CTelephonyAudioRouting::TAudioOutput output = aOutput; |
|
457 |
|
458 TELAUDRTNG_RDEBUG1(_L("[TELAUDRTNG]\t CTelephonyAudioRoutingServer::OutputChanged called with: = %d"), output); |
|
459 |
|
460 iSessionIter.SetToFirst(); |
|
461 |
|
462 CTelephonyAudioRoutingServerSession* serverSession = static_cast<CTelephonyAudioRoutingServerSession*>(iSessionIter++); |
|
463 while (serverSession != NULL) |
|
464 { |
|
465 if(serverSession->SessionId() != iPolicySessionId) |
|
466 { |
|
467 // Always send ETrue if outputChanged initiated by Policy: |
|
468 iShowNoteMode = ETrue; |
|
469 serverSession->OutputChanged(output, iShowNoteMode); |
|
470 |
|
471 } |
|
472 serverSession = static_cast<CTelephonyAudioRoutingServerSession*>(iSessionIter++); |
|
473 } |
|
474 } |
|
475 |
|
476 // ----------------------------------------------------------------------------- |
|
477 // CTelephonyAudioRoutingServer::IsAvailableOutput |
|
478 // Method used to determine if requested audio output is one of the |
|
479 // audio outputs in the available output array. |
|
480 // ----------------------------------------------------------------------------- |
|
481 // |
|
482 TBool CTelephonyAudioRoutingServer::IsAvailableOutput( |
|
483 CTelephonyAudioRouting::TAudioOutput aOutput) |
|
484 { |
|
485 TELAUDRTNG_RDEBUG(_L("[TELAUDRTNG]\t CTelephonyAudioRoutingServer::IsAvailableOutput ")); |
|
486 |
|
487 TBool found = EFalse; |
|
488 CTelephonyAudioRouting::TAudioOutput arrayElement; |
|
489 TInt count = iAvailableOutputs.Count(); |
|
490 |
|
491 for(TInt i=0;i<count;i++) |
|
492 { |
|
493 arrayElement = iAvailableOutputs[i]; |
|
494 if (aOutput == arrayElement) |
|
495 { |
|
496 found = ETrue; |
|
497 break; |
|
498 } |
|
499 |
|
500 } |
|
501 |
|
502 TELAUDRTNG_RDEBUG1(_L("[TELAUDRTNG]\t CTelephonyAudioRoutingServer::IsAvailableOutput: Found? = %d "), found); |
|
503 return found; |
|
504 |
|
505 } |
|
506 |
|
507 // ----------------------------------------------------------------------------- |
|
508 // CTelephonyAudioRoutingServer::CurrentAudioOutput |
|
509 // Accessor method returns iCurrentAudioOutput to caller. |
|
510 // (other items were commented in a header). |
|
511 // ----------------------------------------------------------------------------- |
|
512 // |
|
513 CTelephonyAudioRouting::TAudioOutput& CTelephonyAudioRoutingServer::CurrentAudioOutput() |
|
514 { |
|
515 return iCurrentAudioOutput; |
|
516 } |
|
517 |
|
518 // ----------------------------------------------------------------------------- |
|
519 // CTelephonyAudioRoutingServer::ShowNoteMode |
|
520 // Accessor method returns iShowNoteMode to caller. |
|
521 // (other items were commented in a header). |
|
522 // ----------------------------------------------------------------------------- |
|
523 // |
|
524 TBool& CTelephonyAudioRoutingServer::ShowNoteMode() |
|
525 { |
|
526 return iShowNoteMode; |
|
527 } |
|
528 |
|
529 // ----------------------------------------------------------------------------- |
|
530 // CTelephonyAudioRoutingServer::SetShowNoteMode |
|
531 // Accessor method allows caller to set iShowNoteMode. |
|
532 // (other items were commented in a header). |
|
533 // ----------------------------------------------------------------------------- |
|
534 // |
|
535 void CTelephonyAudioRoutingServer::SetShowNoteMode(TBool aShowNoteMode) |
|
536 { |
|
537 iShowNoteMode = aShowNoteMode; |
|
538 } |
|
539 |
|
540 |
|
541 // ----------------------------------------------------------------------------- |
|
542 // CTelephonyAudioRoutingServer::PreviousAudioOutput |
|
543 // Accessor method returns iPreviousAudioOutput to caller. |
|
544 // (other items were commented in a header). |
|
545 // ----------------------------------------------------------------------------- |
|
546 // |
|
547 CTelephonyAudioRouting::TAudioOutput& CTelephonyAudioRoutingServer::PreviousAudioOutput() |
|
548 { |
|
549 return iPreviousAudioOutput; |
|
550 } |
|
551 |
|
552 // ----------------------------------------------------------------------------- |
|
553 // CTelephonyAudioRoutingServer::AvailableOutputs |
|
554 // Accessor method returns iAvailableOutputs to caller. |
|
555 // (other items were commented in a header). |
|
556 // ----------------------------------------------------------------------------- |
|
557 // |
|
558 RArray<CTelephonyAudioRouting::TAudioOutput>& CTelephonyAudioRoutingServer::AvailableOutputs() |
|
559 { |
|
560 return iAvailableOutputs; |
|
561 } |
|
562 |
|
563 |
|
564 //End of File |