os/mm/inc/AudioResourceProxyAO.h
author sl
Tue, 10 Jun 2014 14:32:02 +0200
changeset 1 260cb5ec6c19
permissions -rw-r--r--
Update contrib.
sl@0
     1
/*
sl@0
     2
* Copyright (c) 2005 Nokia Corporation and/or its subsidiary(-ies). 
sl@0
     3
* All rights reserved.
sl@0
     4
* This component and the accompanying materials are made available
sl@0
     5
* under the terms of "Eclipse Public License v1.0"
sl@0
     6
* which accompanies this distribution, and is available
sl@0
     7
* at the URL "http://www.eclipse.org/legal/epl-v10.html".
sl@0
     8
*
sl@0
     9
* Initial Contributors:
sl@0
    10
* Nokia Corporation - initial contribution.
sl@0
    11
*
sl@0
    12
* Contributors:
sl@0
    13
*
sl@0
    14
* Description:  This is the class handles Message Handling between Audio Resrouce
sl@0
    15
*                and Adaption layer
sl@0
    16
*
sl@0
    17
*
sl@0
    18
*/
sl@0
    19
sl@0
    20
#ifndef CAUDIORESOURCEPROXYAO_H
sl@0
    21
#define CAUDIORESOURCEPROXYAO_H
sl@0
    22
sl@0
    23
//  INCLUDES
sl@0
    24
#include <e32base.h>
sl@0
    25
#include <mmfcontrollerframework.h>
sl@0
    26
#include <MCustomCommand.h>
sl@0
    27
sl@0
    28
// FORWARD DECLARATIONS
sl@0
    29
class CCustomCommandUtility;
sl@0
    30
class CAudioResourceUtilityProxy;
sl@0
    31
//class CAudioOutput;
sl@0
    32
sl@0
    33
// CLASS DECLARATION
sl@0
    34
sl@0
    35
/**
sl@0
    36
*  This is the Audio Resource proxy Active object class responsible for handling callback messages.
sl@0
    37
*
sl@0
    38
*  @lib AudioResourceProxy.lib
sl@0
    39
*  @since 3.0
sl@0
    40
*/
sl@0
    41
class CAudioResourceProxyAO : public CActive
sl@0
    42
    {
sl@0
    43
    public:
sl@0
    44
        /**
sl@0
    45
        * Two-phased constructor.
sl@0
    46
        */
sl@0
    47
        static CAudioResourceProxyAO* NewL(CAudioResourceUtility *aResourceProxy,
sl@0
    48
        								MAudioResourceUtilityObserver& aObserver,
sl@0
    49
        								MCustomCommand* aUtility);
sl@0
    50
sl@0
    51
        virtual ~CAudioResourceProxyAO();
sl@0
    52
sl@0
    53
		/**
sl@0
    54
        * Send Asyncronous Message
sl@0
    55
        * @since 3.0
sl@0
    56
        */
sl@0
    57
		void SendAsyncMessage(const TMMFMessageDestinationPckg& aDestination,
sl@0
    58
	                                      TInt aFunction );
sl@0
    59
sl@0
    60
		void SetRegisterFlag(TBool aFlag);
sl@0
    61
sl@0
    62
    private:
sl@0
    63
sl@0
    64
        /**
sl@0
    65
        * C++ default constructor.
sl@0
    66
        */
sl@0
    67
        CAudioResourceProxyAO(CAudioResourceUtility *aResourceProxy,
sl@0
    68
        					MAudioResourceUtilityObserver& aObserver,
sl@0
    69
        					MCustomCommand* aUtility);
sl@0
    70
sl@0
    71
        /**
sl@0
    72
        * By default Symbian 2nd phase constructor is private.
sl@0
    73
        */
sl@0
    74
        void ConstructL();
sl@0
    75
sl@0
    76
        void RunL();
sl@0
    77
sl@0
    78
        void DoCancel();
sl@0
    79
sl@0
    80
	private:
sl@0
    81
		CAudioResourceUtility*				iAudioResourceProxy;
sl@0
    82
		MAudioResourceUtilityObserver&		iObserver;
sl@0
    83
		MCustomCommand*				iCustomCommandUtility;
sl@0
    84
		const TMMFMessageDestinationPckg*				iDestination;
sl@0
    85
		TInt											iFunction;
sl@0
    86
		TBool											iRegistered;
sl@0
    87
sl@0
    88
    };
sl@0
    89
sl@0
    90
#endif 		// CAUDIORESOURCEPROXYAO_H