equal
deleted
inserted
replaced
224 iAudioPlayer = NULL; |
224 iAudioPlayer = NULL; |
225 |
225 |
226 MProfile* profile = iProfileEngine->ActiveProfileL(); |
226 MProfile* profile = iProfileEngine->ActiveProfileL(); |
227 CleanupReleasePushL( *profile ); |
227 CleanupReleasePushL( *profile ); |
228 |
228 |
|
229 TBool vibraEnabled = profile->ProfileTones().ToneSettings().iEmailVibratingAlert; |
|
230 |
|
231 |
|
232 TInt preference = KAudioPrefNewSMS; |
|
233 if ( !vibraEnabled ) |
|
234 { |
|
235 preference = EMdaPriorityPreferenceTimeAndQuality; |
|
236 } |
|
237 |
229 if ( IsBeepOnceSetL( *profile ) ) |
238 if ( IsBeepOnceSetL( *profile ) ) |
230 { |
239 { |
|
240 |
|
241 |
231 // create audio player based on hard coded sequence |
242 // create audio player based on hard coded sequence |
232 // (Platform does not offer any "play platform-wide beep" service) |
243 // (Platform does not offer any "play platform-wide beep" service) |
233 iAudioPlayer = CMdaAudioPlayerUtility::NewDesPlayerReadOnlyL( |
244 iAudioPlayer = CMdaAudioPlayerUtility::NewDesPlayerReadOnlyL( |
234 KEmailBeepSequence(), |
245 KEmailBeepSequence(), |
235 *this, |
246 *this, |
236 KAudioPriorityRecvMsg, |
247 KAudioPriorityRecvMsg, |
237 static_cast<TMdaPriorityPreference>( KAudioPrefNewSMS ) ); |
248 preference ); |
238 } |
249 } |
239 else |
250 else |
240 { |
251 { |
241 // Otherwise loading tone from file |
252 // Otherwise loading tone from file |
242 TFileName fileToPlay = profile->ProfileExtraTones().EmailAlertTone(); |
253 TFileName fileToPlay = profile->ProfileExtraTones().EmailAlertTone(); |
270 |
281 |
271 iAudioPlayer = CMdaAudioPlayerUtility::NewFilePlayerL( |
282 iAudioPlayer = CMdaAudioPlayerUtility::NewFilePlayerL( |
272 fileToPlay, |
283 fileToPlay, |
273 *this, |
284 *this, |
274 KAudioPriorityRecvMsg, |
285 KAudioPriorityRecvMsg, |
275 static_cast<TMdaPriorityPreference>( KAudioPrefNewSMS ) ); |
286 static_cast<TMdaPriorityPreference>( preference ) ); |
276 } |
287 } |
277 CleanupStack::PopAndDestroy( profile ); // profile |
288 CleanupStack::PopAndDestroy( profile ); // profile |
278 } |
289 } |
279 |
290 |
280 // --------------------------------------------------------------------------- |
291 // --------------------------------------------------------------------------- |