os/mm/inc/AudioOutputProxyAO.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-2006 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:  AudioOutput Proxy Active Object
sl@0
    15
*
sl@0
    16
*/
sl@0
    17
sl@0
    18
#ifndef CAUDIOOUTPUTPROXYAO_H
sl@0
    19
#define CAUDIOOUTPUTPROXYAO_H
sl@0
    20
sl@0
    21
//  INCLUDES
sl@0
    22
#include <e32base.h>
sl@0
    23
#include <mmf/common/mmfcontrollerframework.h>
sl@0
    24
#include <MCustomCommand.h>
sl@0
    25
// FORWARD DECLARATIONS
sl@0
    26
class CCustomCommandUtility;
sl@0
    27
class CAudioOutputProxy;
sl@0
    28
//class CAudioOutput;
sl@0
    29
sl@0
    30
// CLASS DECLARATION
sl@0
    31
sl@0
    32
/**
sl@0
    33
*  ?one_line_short_description.
sl@0
    34
*  ?other_description_lines
sl@0
    35
*/
sl@0
    36
class CAudioOutputProxyAO : public CActive
sl@0
    37
    {
sl@0
    38
    public:
sl@0
    39
        /**
sl@0
    40
        * Two-phased constructor.
sl@0
    41
        */
sl@0
    42
        static CAudioOutputProxyAO* NewL(CAudioOutput *aOutputProxy,MAudioOutputObserver& aObserver,MCustomCommand* aUtility);
sl@0
    43
sl@0
    44
        virtual ~CAudioOutputProxyAO();
sl@0
    45
sl@0
    46
		/**
sl@0
    47
        * ?member_description.
sl@0
    48
        * @since Series 60 3.0
sl@0
    49
        * @param aDestination Handle of the message handler
sl@0
    50
        * @param aFunction Message handler function
sl@0
    51
        * @return void
sl@0
    52
        */
sl@0
    53
		void SendAsyncMessage(const TMMFMessageDestinationPckg& aDestination,
sl@0
    54
	                                      TInt aFunction );
sl@0
    55
sl@0
    56
		/**
sl@0
    57
        * ?member_description.
sl@0
    58
        * @since Series 60 3.0
sl@0
    59
        * @param aFlag EFalse=unregistered, ETrue=registered
sl@0
    60
        * @return void
sl@0
    61
        */
sl@0
    62
		void SetRegisterFlag(TBool aFlag);
sl@0
    63
		
sl@0
    64
		/**
sl@0
    65
        * ?member_description.
sl@0
    66
        * @since Series 60 3.0
sl@0
    67
        * @param aObserver Observer Instance
sl@0
    68
        * @return void
sl@0
    69
        */
sl@0
    70
		void SetObserver(MAudioOutputObserver& aObserver);
sl@0
    71
sl@0
    72
sl@0
    73
    private:
sl@0
    74
sl@0
    75
        /**
sl@0
    76
        * C++ default constructor.
sl@0
    77
        */
sl@0
    78
        CAudioOutputProxyAO(CAudioOutput *aOutputProxy,MAudioOutputObserver& aObserver,MCustomCommand* aUtility);
sl@0
    79
sl@0
    80
        /**
sl@0
    81
        * By default Symbian 2nd phase constructor is private.
sl@0
    82
        */
sl@0
    83
        void ConstructL();
sl@0
    84
sl@0
    85
		// Functions from base classes
sl@0
    86
sl@0
    87
        /**
sl@0
    88
        * From CActive ?member_description
sl@0
    89
        */
sl@0
    90
        void RunL();
sl@0
    91
sl@0
    92
        /**
sl@0
    93
        * From CActive ?member_description
sl@0
    94
        */
sl@0
    95
        void DoCancel();
sl@0
    96
sl@0
    97
	private:
sl@0
    98
		CAudioOutput*									iAudioOutputProxy;
sl@0
    99
		MCustomCommand*							iCustomCommandUtility;
sl@0
   100
		TPckgBuf<CAudioOutput::TAudioOutputPreference>	iCallbackData;
sl@0
   101
		MAudioOutputObserver*							iObserver;
sl@0
   102
		const TMMFMessageDestinationPckg*				iDestination;
sl@0
   103
		TInt											iFunction;
sl@0
   104
		TBool											iRegistered;
sl@0
   105
sl@0
   106
sl@0
   107
    };
sl@0
   108
sl@0
   109
#endif 		// CAUDIOOUTPUTPROXYAO_H