inc/AudioResourceProxyAO.h
changeset 0 40261b775718
equal deleted inserted replaced
-1:000000000000 0:40261b775718
       
     1 /*
       
     2 * Copyright (c) 2005 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:  This is the class handles Message Handling between Audio Resrouce
       
    15 *                and Adaption layer
       
    16 *
       
    17 *
       
    18 */
       
    19 
       
    20 #ifndef CAUDIORESOURCEPROXYAO_H
       
    21 #define CAUDIORESOURCEPROXYAO_H
       
    22 
       
    23 //  INCLUDES
       
    24 #include <e32base.h>
       
    25 #include <mmfcontrollerframework.h>
       
    26 #include <MCustomCommand.h>
       
    27 
       
    28 // FORWARD DECLARATIONS
       
    29 class CCustomCommandUtility;
       
    30 class CAudioResourceUtilityProxy;
       
    31 //class CAudioOutput;
       
    32 
       
    33 // CLASS DECLARATION
       
    34 
       
    35 /**
       
    36 *  This is the Audio Resource proxy Active object class responsible for handling callback messages.
       
    37 *
       
    38 *  @lib AudioResourceProxy.lib
       
    39 *  @since 3.0
       
    40 */
       
    41 class CAudioResourceProxyAO : public CActive
       
    42     {
       
    43     public:
       
    44         /**
       
    45         * Two-phased constructor.
       
    46         */
       
    47         static CAudioResourceProxyAO* NewL(CAudioResourceUtility *aResourceProxy,
       
    48         								MAudioResourceUtilityObserver& aObserver,
       
    49         								MCustomCommand* aUtility);
       
    50 
       
    51         virtual ~CAudioResourceProxyAO();
       
    52 
       
    53 		/**
       
    54         * Send Asyncronous Message
       
    55         * @since 3.0
       
    56         */
       
    57 		void SendAsyncMessage(const TMMFMessageDestinationPckg& aDestination,
       
    58 	                                      TInt aFunction );
       
    59 
       
    60 		void SetRegisterFlag(TBool aFlag);
       
    61 
       
    62     private:
       
    63 
       
    64         /**
       
    65         * C++ default constructor.
       
    66         */
       
    67         CAudioResourceProxyAO(CAudioResourceUtility *aResourceProxy,
       
    68         					MAudioResourceUtilityObserver& aObserver,
       
    69         					MCustomCommand* aUtility);
       
    70 
       
    71         /**
       
    72         * By default Symbian 2nd phase constructor is private.
       
    73         */
       
    74         void ConstructL();
       
    75 
       
    76         void RunL();
       
    77 
       
    78         void DoCancel();
       
    79 
       
    80 	private:
       
    81 		CAudioResourceUtility*				iAudioResourceProxy;
       
    82 		MAudioResourceUtilityObserver&		iObserver;
       
    83 		MCustomCommand*				iCustomCommandUtility;
       
    84 		const TMMFMessageDestinationPckg*				iDestination;
       
    85 		TInt											iFunction;
       
    86 		TBool											iRegistered;
       
    87 
       
    88     };
       
    89 
       
    90 #endif 		// CAUDIORESOURCEPROXYAO_H