24
|
1 |
/*
|
|
2 |
* Copyright (c) 2005-2009 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:
|
|
15 |
*
|
|
16 |
*/
|
|
17 |
|
|
18 |
|
|
19 |
#ifndef T_CAUDIO_OUTPUT_H
|
|
20 |
#define T_CAUDIO_OUTPUT_H
|
|
21 |
|
|
22 |
//User Includes
|
|
23 |
#include "DataWrapperBase.h"
|
|
24 |
|
|
25 |
//Epoc Includes
|
|
26 |
#include <audiooutput.h>//CAudioOutput
|
|
27 |
#include <audiooutputmessagetypes.h>
|
|
28 |
#include <maudiooutputobserver.h>
|
|
29 |
#include <sounddevice.h>//CMMFDevSound
|
|
30 |
|
|
31 |
class CT_CAudioOutputData : public CDataWrapperBase, public MAudioOutputObserver
|
|
32 |
{
|
|
33 |
public:
|
|
34 |
static CT_CAudioOutputData* NewL();
|
|
35 |
virtual TAny* GetObject();
|
|
36 |
virtual TBool DoCommandL(const TTEFFunction& aCommand, const TTEFSectionName& aSection, const TInt aAsyncErrorIndex);
|
|
37 |
CT_CAudioOutputData();
|
|
38 |
|
|
39 |
private:
|
|
40 |
void DestroyData();
|
|
41 |
|
|
42 |
protected:
|
|
43 |
void DoCmdNewL(const TTEFSectionName& aSection);
|
|
44 |
void DoCmdDestructor();
|
|
45 |
|
|
46 |
void DoCmdAudioOutput();
|
|
47 |
void DoCmdDefaultAudioOutput();
|
|
48 |
void DoCmdRegisterObserverL();
|
|
49 |
void DoCmdSecureOutput();
|
|
50 |
void DoCmdSetAudioOutputL(const TTEFSectionName& aSection);
|
|
51 |
void DoCmdSetSecureOutputL(const TTEFSectionName& aSection);
|
|
52 |
void DoCmdUnregisterObserver();
|
|
53 |
|
|
54 |
public:
|
|
55 |
/**
|
|
56 |
* From MAudioOutputObserver.
|
|
57 |
*/
|
|
58 |
void DefaultAudioOutputChanged( CAudioOutput& aAudioOutput, CAudioOutput::TAudioOutputPreference aNewDefault );
|
|
59 |
|
|
60 |
private:
|
|
61 |
/**
|
|
62 |
* Wrapped object
|
|
63 |
*/
|
|
64 |
CAudioOutput* iAudioOutput;
|
|
65 |
/**
|
|
66 |
* Pref of audio output
|
|
67 |
*/
|
|
68 |
CAudioOutput::TAudioOutputPreference audioOutputPref;
|
|
69 |
/**
|
|
70 |
* Secure Output(DoCmdSecureOutput)
|
|
71 |
*/
|
|
72 |
TBool iSecureOutput;
|
|
73 |
/**
|
|
74 |
* Enum for output options
|
|
75 |
*/
|
|
76 |
static const TEnumEntryTable iEnumOutputOptions[];
|
|
77 |
};
|
|
78 |
|
|
79 |
|
|
80 |
#endif //T_CAUDIO_OUTPUT_H
|
|
81 |
|