18
|
1 |
/*
|
|
2 |
* Copyright (c) 2007 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: Blid application arrived tone player utility class declaration.
|
|
15 |
*
|
|
16 |
*/
|
|
17 |
|
|
18 |
|
|
19 |
|
|
20 |
#ifndef __CBLIDARRIVEDTONEPLAYERUTILITY_H__
|
|
21 |
#define __CBLIDARRIVEDTONEPLAYERUTILITY_H__
|
|
22 |
|
|
23 |
// SYSTEM INCLUDES
|
|
24 |
#include <mdaaudiosampleplayer.h>
|
|
25 |
// USER INCLUDES
|
|
26 |
|
|
27 |
// FORWARD DECLARATION
|
|
28 |
|
|
29 |
/*
|
|
30 |
* @description
|
|
31 |
*
|
|
32 |
*/
|
|
33 |
class CBlidArrivedTonePlayerUtility : public CBase,
|
|
34 |
public MMdaAudioPlayerCallback
|
|
35 |
{
|
|
36 |
public:
|
|
37 |
/**
|
|
38 |
* Two-phased constructor.
|
|
39 |
*/
|
|
40 |
static CBlidArrivedTonePlayerUtility* NewL( );
|
|
41 |
|
|
42 |
/**
|
|
43 |
* Destructor.
|
|
44 |
*/
|
|
45 |
~CBlidArrivedTonePlayerUtility();
|
|
46 |
|
|
47 |
public: // from MMdaAudioPlayerCallback
|
|
48 |
/**
|
|
49 |
* From MMdaAudioPlayerCallback Called when audio clip initialization completes.
|
|
50 |
*
|
|
51 |
* @since 2.0
|
|
52 |
*
|
|
53 |
* @param aError IN Resulting error code.
|
|
54 |
* @param aDuration IN Audio clip duration.
|
|
55 |
*
|
|
56 |
* @return void
|
|
57 |
*/
|
|
58 |
void MapcInitComplete( TInt aError,
|
|
59 |
const TTimeIntervalMicroSeconds& aDuration );
|
|
60 |
|
|
61 |
/**
|
|
62 |
* From MMdaAudioPlayerCallback Called when audio clip playback completes.
|
|
63 |
*
|
|
64 |
* @since 2.0
|
|
65 |
*
|
|
66 |
* @param aError IN Resulting error code.
|
|
67 |
*
|
|
68 |
* @return void
|
|
69 |
*/
|
|
70 |
void MapcPlayComplete( TInt aError );
|
|
71 |
|
|
72 |
|
|
73 |
private:
|
|
74 |
/**
|
|
75 |
* C++ default constructor.
|
|
76 |
*/
|
|
77 |
CBlidArrivedTonePlayerUtility();
|
|
78 |
|
|
79 |
/**
|
|
80 |
* By default Symbian 2nd phase constructor is private.
|
|
81 |
*/
|
|
82 |
void ConstructL( );
|
|
83 |
|
|
84 |
public:
|
|
85 |
void PlayToneL( const TFileName& aFileName );
|
|
86 |
void CanclePayer();
|
|
87 |
|
|
88 |
private:
|
|
89 |
// Audio player utility.
|
|
90 |
CMdaAudioPlayerUtility* iAudioPlayer;
|
|
91 |
TFileName iFileName;
|
|
92 |
TTimeIntervalMicroSeconds iAudioDuration;
|
|
93 |
};
|
|
94 |
|
|
95 |
#endif // __CBLIDARRIVEDTONEPLAYERUTILITY_H__ |