19 #include <AudioOutput.h> |
19 #include <AudioOutput.h> |
20 |
20 |
21 // User includes |
21 // User includes |
22 #include "cradioroutableaudio.h" |
22 #include "cradioroutableaudio.h" |
23 #include "cradioaudiorouter.h" |
23 #include "cradioaudiorouter.h" |
|
24 #include "cradioenginelogger.h" |
24 |
25 |
25 |
26 |
26 // --------------------------------------------------------------------------- |
27 // --------------------------------------------------------------------------- |
27 // |
28 // |
28 // --------------------------------------------------------------------------- |
29 // --------------------------------------------------------------------------- |
29 // |
30 // |
30 EXPORT_C CRadioRoutableAudio::CRadioRoutableAudio( CRadioAudioRouter* aAudioRouter ) |
31 EXPORT_C CRadioRoutableAudio::CRadioRoutableAudio( CRadioAudioRouter* aAudioRouter ) |
31 : iAudioRouter( aAudioRouter ) |
32 : iAudioRouter( aAudioRouter ) |
32 { |
33 { |
|
34 LEVEL3( LOG_METHOD_AUTO ); |
33 iAudioRouter->RegisterRoutableAudio( this ); |
35 iAudioRouter->RegisterRoutableAudio( this ); |
34 } |
36 } |
35 |
37 |
36 // --------------------------------------------------------------------------- |
38 // --------------------------------------------------------------------------- |
37 // |
39 // |
49 // |
51 // |
50 // --------------------------------------------------------------------------- |
52 // --------------------------------------------------------------------------- |
51 // |
53 // |
52 EXPORT_C void CRadioRoutableAudio::SetAudioOutput( CAudioOutput* aAudioOutput ) |
54 EXPORT_C void CRadioRoutableAudio::SetAudioOutput( CAudioOutput* aAudioOutput ) |
53 { |
55 { |
|
56 LEVEL3( LOG_METHOD_AUTO ); |
54 delete iAudioOutput; |
57 delete iAudioOutput; |
55 iAudioOutput = aAudioOutput; |
58 iAudioOutput = aAudioOutput; |
56 } |
59 } |
57 |
60 |
58 // --------------------------------------------------------------------------- |
61 // --------------------------------------------------------------------------- |
59 // |
62 // |
60 // --------------------------------------------------------------------------- |
63 // --------------------------------------------------------------------------- |
61 // |
64 // |
62 EXPORT_C void CRadioRoutableAudio::DeleteAudioOutput() |
65 EXPORT_C void CRadioRoutableAudio::DeleteAudioOutput() |
63 { |
66 { |
|
67 LEVEL3( LOG_METHOD_AUTO ); |
64 delete iAudioOutput; |
68 delete iAudioOutput; |
65 iAudioOutput = NULL; |
69 iAudioOutput = NULL; |
66 } |
70 } |
67 |
71 |
68 // --------------------------------------------------------------------------- |
72 // --------------------------------------------------------------------------- |
69 // |
73 // |
70 // --------------------------------------------------------------------------- |
74 // --------------------------------------------------------------------------- |
71 // |
75 // |
72 EXPORT_C void CRadioRoutableAudio::SetAudioRouteL( RadioEngine::TRadioAudioRoute aRoute ) |
76 EXPORT_C void CRadioRoutableAudio::SetAudioRouteL( RadioEngine::TRadioAudioRoute aRoute ) |
73 { |
77 { |
|
78 LEVEL3( LOG_METHOD_AUTO ); |
74 if ( iAudioOutput ) |
79 if ( iAudioOutput ) |
75 { |
80 { |
76 iAudioOutput->SetAudioOutputL( aRoute == RadioEngine::ERadioSpeaker ? CAudioOutput::EPublic |
81 iAudioOutput->SetAudioOutputL( aRoute == RadioEngine::ERadioSpeaker ? CAudioOutput::EPublic |
77 : CAudioOutput::EPrivate ); |
82 : CAudioOutput::EPrivate ); |
78 } |
83 } |