devsoundextensions/mmextfw/customcommandutility/src/CustomCommandUtility.cpp
author hgs
Thu, 07 Oct 2010 22:34:12 +0100
changeset 0 b8ed18f6c07b
child 5 b220a9341636
permissions -rw-r--r--
2010wk40
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
0
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
     1
/*
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
     2
* Copyright (c) 2004 Nokia Corporation and/or its subsidiary(-ies). 
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
     3
* All rights reserved.
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
     4
* This component and the accompanying materials are made available
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
     5
* under the terms of "Eclipse Public License v1.0"
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
     6
* which accompanies this distribution, and is available
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
     7
* at the URL "http://www.eclipse.org/legal/epl-v10.html".
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
     8
*
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
     9
* Initial Contributors:
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    10
* Nokia Corporation - initial contribution.
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    11
*
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    12
* Contributors:
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    13
*
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    14
* Description:    Custom command utility implementation
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    15
*
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    16
*/
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    17
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    18
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    19
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    20
#include <mdaaudiosampleplayer.h>
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    21
#include <mdaaudiosampleeditor.h>
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    22
#include <midiclientutility.h>
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    23
#include <DrmAudioSamplePlayer.h>
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    24
#include <CustomCommandUtility.h>
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    25
#include <videoplayer.h>
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    26
#include <videorecorder.h>
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    27
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    28
class CConvertCustomCommandUtility : public CCustomCommandUtility
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    29
	{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    30
public:
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    31
	CConvertCustomCommandUtility(CMdaAudioConvertUtility& aUtility) :
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    32
		iUtility(aUtility)
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    33
		{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    34
		}
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    35
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    36
	virtual TInt CustomCommandSync(const TMMFMessageDestinationPckg&  aDestination,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    37
	                                     TInt                         aFunction,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    38
	                               const TDesC8&                      aDataTo1,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    39
	                               const TDesC8&                      aDataTo2,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    40
	                                     TDes8&                       aDataFrom)
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    41
		{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    42
		return iUtility.CustomCommandSync(aDestination, aFunction, aDataTo1, aDataTo2, aDataFrom);
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    43
		}
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    44
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    45
	virtual TInt CustomCommandSync(const TMMFMessageDestinationPckg&  aDestination,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    46
	                                     TInt                         aFunction,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    47
	                               const TDesC8&                      aDataTo1,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    48
	                               const TDesC8&                      aDataTo2)
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    49
		{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    50
		return iUtility.CustomCommandSync(aDestination, aFunction, aDataTo1, aDataTo2);
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    51
		}
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    52
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    53
	virtual void CustomCommandAsync(const TMMFMessageDestinationPckg& aDestination,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    54
	                                      TInt                        aFunction,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    55
	                                const TDesC8&                     aDataTo1,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    56
	                                const TDesC8&                     aDataTo2,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    57
	                                      TDes8&                      aDataFrom,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    58
	                                      TRequestStatus&             aStatus)
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    59
		{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    60
		iUtility.CustomCommandAsync(aDestination, aFunction, aDataTo1, aDataTo2, aDataFrom, aStatus);
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    61
		}
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    62
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    63
	virtual void CustomCommandAsync(const TMMFMessageDestinationPckg& aDestination,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    64
	                                      TInt                        aFunction,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    65
	                                const TDesC8&                     aDataTo1,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    66
	                                const TDesC8&                     aDataTo2,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    67
	                                      TRequestStatus&             aStatus)
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    68
		{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    69
		iUtility.CustomCommandAsync(aDestination, aFunction, aDataTo1, aDataTo2, aStatus);
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    70
		}
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    71
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    72
private:
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    73
	CMdaAudioConvertUtility& iUtility;
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    74
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    75
	};
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    76
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    77
class CPlayerCustomCommandUtility : public CCustomCommandUtility
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    78
	{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    79
public:
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    80
	CPlayerCustomCommandUtility(CMdaAudioPlayerUtility& aUtility) :
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    81
		iUtility(aUtility)
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    82
		{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    83
		}
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    84
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    85
	virtual TInt CustomCommandSync(const TMMFMessageDestinationPckg&  aDestination,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    86
	                                     TInt                         aFunction,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    87
	                               const TDesC8&                      aDataTo1,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    88
	                               const TDesC8&                      aDataTo2,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    89
	                                     TDes8&                       aDataFrom)
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    90
		{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    91
		return iUtility.CustomCommandSync(aDestination, aFunction, aDataTo1, aDataTo2, aDataFrom);
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    92
		}
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    93
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    94
	virtual TInt CustomCommandSync(const TMMFMessageDestinationPckg&  aDestination,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    95
	                                     TInt                         aFunction,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    96
	                               const TDesC8&                      aDataTo1,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    97
	                               const TDesC8&                      aDataTo2)
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    98
		{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
    99
		return iUtility.CustomCommandSync(aDestination, aFunction, aDataTo1, aDataTo2);
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   100
		}
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   101
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   102
	virtual void CustomCommandAsync(const TMMFMessageDestinationPckg& aDestination,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   103
	                                      TInt                        aFunction,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   104
	                                const TDesC8&                     aDataTo1,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   105
	                                const TDesC8&                     aDataTo2,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   106
	                                      TDes8&                      aDataFrom,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   107
	                                      TRequestStatus&             aStatus)
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   108
		{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   109
		iUtility.CustomCommandAsync(aDestination, aFunction, aDataTo1, aDataTo2, aDataFrom, aStatus);
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   110
		}
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   111
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   112
	virtual void CustomCommandAsync(const TMMFMessageDestinationPckg& aDestination,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   113
	                                      TInt                        aFunction,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   114
	                                const TDesC8&                     aDataTo1,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   115
	                                const TDesC8&                     aDataTo2,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   116
	                                      TRequestStatus&             aStatus)
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   117
		{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   118
		iUtility.CustomCommandAsync(aDestination, aFunction, aDataTo1, aDataTo2, aStatus);
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   119
		}
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   120
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   121
private:
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   122
	CMdaAudioPlayerUtility& iUtility;
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   123
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   124
	};
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   125
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   126
class CRecorderCustomCommandUtility : public CCustomCommandUtility
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   127
	{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   128
public:
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   129
	CRecorderCustomCommandUtility(CMdaAudioRecorderUtility& aUtility) :
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   130
		iUtility(aUtility)
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   131
		{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   132
		}
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   133
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   134
	virtual TInt CustomCommandSync(const TMMFMessageDestinationPckg&  aDestination,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   135
	                                     TInt                         aFunction,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   136
	                               const TDesC8&                      aDataTo1,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   137
	                               const TDesC8&                      aDataTo2,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   138
	                                     TDes8&                       aDataFrom)
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   139
		{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   140
		return iUtility.RecordControllerCustomCommandSync(aDestination, aFunction, aDataTo1, aDataTo2, aDataFrom);
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   141
		}
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   142
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   143
	virtual TInt CustomCommandSync(const TMMFMessageDestinationPckg&  aDestination,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   144
	                                     TInt                         aFunction,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   145
	                               const TDesC8&                      aDataTo1,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   146
	                               const TDesC8&                      aDataTo2)
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   147
		{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   148
		return iUtility.RecordControllerCustomCommandSync(aDestination, aFunction, aDataTo1, aDataTo2);
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   149
		}
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   150
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   151
	virtual void CustomCommandAsync(const TMMFMessageDestinationPckg& aDestination,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   152
	                                      TInt                        aFunction,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   153
	                                const TDesC8&                     aDataTo1,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   154
	                                const TDesC8&                     aDataTo2,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   155
	                                      TDes8&                      aDataFrom,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   156
	                                      TRequestStatus&             aStatus)
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   157
		{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   158
		iUtility.RecordControllerCustomCommandAsync(aDestination, aFunction, aDataTo1, aDataTo2, aDataFrom, aStatus);
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   159
		}
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   160
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   161
	virtual void CustomCommandAsync(const TMMFMessageDestinationPckg& aDestination,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   162
	                                      TInt                        aFunction,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   163
	                                const TDesC8&                     aDataTo1,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   164
	                                const TDesC8&                     aDataTo2,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   165
	                                      TRequestStatus&             aStatus)
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   166
		{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   167
		iUtility.RecordControllerCustomCommandAsync(aDestination, aFunction, aDataTo1, aDataTo2, aStatus);
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   168
		}
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   169
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   170
private:
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   171
	CMdaAudioRecorderUtility& iUtility;
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   172
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   173
	};
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   174
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   175
class CRecorderPlayCustomCommandUtility : public CCustomCommandUtility
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   176
	{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   177
public:
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   178
	CRecorderPlayCustomCommandUtility(CMdaAudioRecorderUtility& aUtility) :
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   179
		iUtility(aUtility)
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   180
		{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   181
		}
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   182
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   183
	virtual TInt CustomCommandSync(const TMMFMessageDestinationPckg&  aDestination,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   184
	                                     TInt                         aFunction,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   185
	                               const TDesC8&                      aDataTo1,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   186
	                               const TDesC8&                      aDataTo2,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   187
	                                     TDes8&                       aDataFrom)
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   188
		{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   189
		return iUtility.PlayControllerCustomCommandSync(aDestination, aFunction, aDataTo1, aDataTo2, aDataFrom);
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   190
		}
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   191
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   192
	virtual TInt CustomCommandSync(const TMMFMessageDestinationPckg&  aDestination,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   193
	                                     TInt                         aFunction,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   194
	                               const TDesC8&                      aDataTo1,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   195
	                               const TDesC8&                      aDataTo2)
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   196
		{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   197
		return iUtility.PlayControllerCustomCommandSync(aDestination, aFunction, aDataTo1, aDataTo2);
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   198
		}
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   199
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   200
	virtual void CustomCommandAsync(const TMMFMessageDestinationPckg& aDestination,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   201
	                                      TInt                        aFunction,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   202
	                                const TDesC8&                     aDataTo1,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   203
	                                const TDesC8&                     aDataTo2,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   204
	                                      TDes8&                      aDataFrom,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   205
	                                      TRequestStatus&             aStatus)
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   206
		{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   207
		iUtility.PlayControllerCustomCommandAsync(aDestination, aFunction, aDataTo1, aDataTo2, aDataFrom, aStatus);
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   208
		}
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   209
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   210
	virtual void CustomCommandAsync(const TMMFMessageDestinationPckg& aDestination,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   211
	                                      TInt                        aFunction,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   212
	                                const TDesC8&                     aDataTo1,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   213
	                                const TDesC8&                     aDataTo2,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   214
	                                      TRequestStatus&             aStatus)
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   215
		{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   216
		iUtility.PlayControllerCustomCommandAsync(aDestination, aFunction, aDataTo1, aDataTo2, aStatus);
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   217
		}
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   218
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   219
private:
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   220
	CMdaAudioRecorderUtility& iUtility;
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   221
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   222
	};
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   223
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   224
class CMidiCustomCommandUtility : public CCustomCommandUtility
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   225
	{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   226
public:
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   227
	CMidiCustomCommandUtility(CMidiClientUtility& aUtility) :
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   228
		iUtility(aUtility)
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   229
		{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   230
		}
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   231
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   232
	virtual TInt CustomCommandSync(const TMMFMessageDestinationPckg&  aDestination,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   233
	                                     TInt                         aFunction,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   234
	                               const TDesC8&                      aDataTo1,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   235
	                               const TDesC8&                      aDataTo2,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   236
	                                     TDes8&                       aDataFrom)
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   237
		{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   238
		iUtility.CustomCommandSyncL(aDestination, aFunction, aDataTo1, aDataTo2, aDataFrom);
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   239
		return KErrNone;
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   240
		}
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   241
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   242
	virtual TInt CustomCommandSync(const TMMFMessageDestinationPckg&  aDestination,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   243
	                                     TInt                         aFunction,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   244
	                               const TDesC8&                      aDataTo1,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   245
	                               const TDesC8&                      aDataTo2)
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   246
		{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   247
		iUtility.CustomCommandSyncL(aDestination, aFunction, aDataTo1, aDataTo2);
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   248
		return KErrNone;
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   249
		}
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   250
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   251
	virtual void CustomCommandAsync(const TMMFMessageDestinationPckg& aDestination,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   252
	                                      TInt                        aFunction,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   253
	                                const TDesC8&                     aDataTo1,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   254
	                                const TDesC8&                     aDataTo2,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   255
	                                      TDes8&                      aDataFrom,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   256
	                                      TRequestStatus&             aStatus)
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   257
		{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   258
		iUtility.CustomCommandAsync(aDestination, aFunction, aDataTo1, aDataTo2, aDataFrom, aStatus);
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   259
		}
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   260
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   261
	virtual void CustomCommandAsync(const TMMFMessageDestinationPckg& aDestination,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   262
	                                      TInt                        aFunction,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   263
	                                const TDesC8&                     aDataTo1,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   264
	                                const TDesC8&                     aDataTo2,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   265
	                                      TRequestStatus&             aStatus)
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   266
		{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   267
		iUtility.CustomCommandAsync(aDestination, aFunction, aDataTo1, aDataTo2, aStatus);
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   268
		}
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   269
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   270
private:
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   271
	CMidiClientUtility& iUtility;
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   272
	};
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   273
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   274
class CDrmCustomCommandUtility : public CCustomCommandUtility
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   275
	{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   276
public:
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   277
	CDrmCustomCommandUtility(CDrmPlayerUtility& aUtility) :
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   278
		iUtility(aUtility)
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   279
		{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   280
		}
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   281
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   282
    virtual TInt CustomCommandSync(const TMMFMessageDestinationPckg&  aDestination,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   283
	                                     TInt                         aFunction,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   284
	                               const TDesC8&                      aDataTo1,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   285
	                               const TDesC8&                      aDataTo2,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   286
	                                     TDes8&                       aDataFrom)
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   287
		{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   288
		iUtility.CustomCommandSync(aDestination, aFunction, aDataTo1, aDataTo2, aDataFrom);
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   289
		return KErrNone;
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   290
		}
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   291
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   292
	virtual TInt CustomCommandSync(const TMMFMessageDestinationPckg&  aDestination,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   293
	                                     TInt                         aFunction,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   294
	                               const TDesC8&                      aDataTo1,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   295
	                               const TDesC8&                      aDataTo2)
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   296
		{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   297
		iUtility.CustomCommandSync(aDestination, aFunction, aDataTo1, aDataTo2);
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   298
		return KErrNone;
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   299
		}
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   300
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   301
	virtual void CustomCommandAsync(const TMMFMessageDestinationPckg& aDestination,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   302
	                                      TInt                        aFunction,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   303
	                                const TDesC8&                     aDataTo1,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   304
	                                const TDesC8&                     aDataTo2,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   305
	                                      TDes8&                      aDataFrom,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   306
	                                      TRequestStatus&             aStatus)
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   307
		{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   308
		iUtility.CustomCommandAsync(aDestination, aFunction, aDataTo1, aDataTo2, aDataFrom, aStatus);
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   309
		}
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   310
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   311
	virtual void CustomCommandAsync(const TMMFMessageDestinationPckg& aDestination,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   312
	                                      TInt                        aFunction,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   313
	                                const TDesC8&                     aDataTo1,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   314
	                                const TDesC8&                     aDataTo2,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   315
	                                      TRequestStatus&             aStatus)
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   316
		{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   317
		iUtility.CustomCommandAsync(aDestination, aFunction, aDataTo1, aDataTo2, aStatus);
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   318
		}
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   319
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   320
private:
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   321
	CDrmPlayerUtility& iUtility;
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   322
	};
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   323
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   324
class CVideoRecorderCustomCommandUtility : public CCustomCommandUtility
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   325
	{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   326
public:
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   327
	CVideoRecorderCustomCommandUtility(CVideoRecorderUtility& aUtility) :
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   328
		iUtility(aUtility)
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   329
		{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   330
		}
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   331
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   332
    virtual TInt CustomCommandSync(const TMMFMessageDestinationPckg&  aDestination,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   333
	                                     TInt                         aFunction,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   334
	                               const TDesC8&                      aDataTo1,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   335
	                               const TDesC8&                      aDataTo2,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   336
	                                     TDes8&                       aDataFrom)
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   337
		{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   338
		iUtility.CustomCommandSync(aDestination, aFunction, aDataTo1, aDataTo2, aDataFrom);
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   339
		return KErrNone;
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   340
		}
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   341
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   342
	virtual TInt CustomCommandSync(const TMMFMessageDestinationPckg&  aDestination,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   343
	                                     TInt                         aFunction,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   344
	                               const TDesC8&                      aDataTo1,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   345
	                               const TDesC8&                      aDataTo2)
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   346
		{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   347
		iUtility.CustomCommandSync(aDestination, aFunction, aDataTo1, aDataTo2);
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   348
		return KErrNone;
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   349
		}
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   350
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   351
	virtual void CustomCommandAsync(const TMMFMessageDestinationPckg& aDestination,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   352
	                                      TInt                        aFunction,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   353
	                                const TDesC8&                     aDataTo1,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   354
	                                const TDesC8&                     aDataTo2,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   355
	                                      TDes8&                      aDataFrom,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   356
	                                      TRequestStatus&             aStatus)
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   357
		{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   358
		iUtility.CustomCommandAsync(aDestination, aFunction, aDataTo1, aDataTo2, aDataFrom, aStatus);
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   359
		}
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   360
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   361
	virtual void CustomCommandAsync(const TMMFMessageDestinationPckg& aDestination,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   362
	                                      TInt                        aFunction,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   363
	                                const TDesC8&                     aDataTo1,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   364
	                                const TDesC8&                     aDataTo2,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   365
	                                      TRequestStatus&             aStatus)
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   366
		{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   367
		iUtility.CustomCommandAsync(aDestination, aFunction, aDataTo1, aDataTo2, aStatus);
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   368
		}
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   369
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   370
private:
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   371
	CVideoRecorderUtility& iUtility;
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   372
	};
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   373
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   374
class CVideoPlayerCustomCommandUtility : public CCustomCommandUtility
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   375
	{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   376
public:
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   377
	CVideoPlayerCustomCommandUtility(CVideoPlayerUtility& aUtility) :
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   378
		iUtility(aUtility)
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   379
		{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   380
		}
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   381
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   382
    virtual TInt CustomCommandSync(const TMMFMessageDestinationPckg&  aDestination,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   383
	                                     TInt                         aFunction,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   384
	                               const TDesC8&                      aDataTo1,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   385
	                               const TDesC8&                      aDataTo2,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   386
	                                     TDes8&                       aDataFrom)
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   387
		{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   388
		iUtility.CustomCommandSync(aDestination, aFunction, aDataTo1, aDataTo2, aDataFrom);
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   389
		return KErrNone;
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   390
		}
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   391
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   392
	virtual TInt CustomCommandSync(const TMMFMessageDestinationPckg&  aDestination,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   393
	                                     TInt                         aFunction,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   394
	                               const TDesC8&                      aDataTo1,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   395
	                               const TDesC8&                      aDataTo2)
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   396
		{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   397
		iUtility.CustomCommandSync(aDestination, aFunction, aDataTo1, aDataTo2);
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   398
		return KErrNone;
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   399
		}
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   400
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   401
	virtual void CustomCommandAsync(const TMMFMessageDestinationPckg& aDestination,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   402
	                                      TInt                        aFunction,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   403
	                                const TDesC8&                     aDataTo1,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   404
	                                const TDesC8&                     aDataTo2,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   405
	                                      TDes8&                      aDataFrom,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   406
	                                      TRequestStatus&             aStatus)
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   407
		{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   408
		iUtility.CustomCommandAsync(aDestination, aFunction, aDataTo1, aDataTo2, aDataFrom, aStatus);
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   409
		}
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   410
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   411
	virtual void CustomCommandAsync(const TMMFMessageDestinationPckg& aDestination,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   412
	                                      TInt                        aFunction,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   413
	                                const TDesC8&                     aDataTo1,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   414
	                                const TDesC8&                     aDataTo2,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   415
	                                      TRequestStatus&             aStatus)
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   416
		{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   417
		iUtility.CustomCommandAsync(aDestination, aFunction, aDataTo1, aDataTo2, aStatus);
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   418
		}
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   419
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   420
private:
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   421
	CVideoPlayerUtility& iUtility;
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   422
	};
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   423
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   424
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   425
EXPORT_C CCustomCommandUtility* CCustomCommandUtility::NewL(CMdaAudioConvertUtility& aUtility)
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   426
	{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   427
	CCustomCommandUtility* customCommand;
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   428
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   429
	customCommand = new(ELeave) CConvertCustomCommandUtility(aUtility);
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   430
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   431
	return customCommand;
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   432
	}
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   433
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   434
EXPORT_C CCustomCommandUtility* CCustomCommandUtility::NewL(CMdaAudioPlayerUtility& aUtility)
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   435
	{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   436
	CCustomCommandUtility* customCommand;
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   437
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   438
	customCommand = new(ELeave) CPlayerCustomCommandUtility(aUtility);
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   439
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   440
	return customCommand;
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   441
	}
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   442
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   443
EXPORT_C CCustomCommandUtility* CCustomCommandUtility::NewL(CMdaAudioRecorderUtility& aUtility,
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   444
                                                            TBool       aRecordStream)
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   445
	{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   446
	CCustomCommandUtility* customCommand;
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   447
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   448
	if( !aRecordStream ) //Playing
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   449
		{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   450
		customCommand = new(ELeave) CRecorderPlayCustomCommandUtility(aUtility);
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   451
		}
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   452
	else //Recording
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   453
		{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   454
		customCommand = new(ELeave) CRecorderCustomCommandUtility(aUtility);
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   455
		}
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   456
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   457
	return customCommand;
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   458
	}
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   459
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   460
EXPORT_C CCustomCommandUtility* CCustomCommandUtility::NewL(CMidiClientUtility& aUtility)
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   461
	{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   462
	CCustomCommandUtility* customCommand;
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   463
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   464
	customCommand = new(ELeave) CMidiCustomCommandUtility(aUtility);
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   465
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   466
	return customCommand;
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   467
	}
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   468
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   469
EXPORT_C CCustomCommandUtility* CCustomCommandUtility::NewL(CDrmPlayerUtility& aUtility)
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   470
	{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   471
	CCustomCommandUtility* customCommand;
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   472
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   473
	customCommand = new(ELeave) CDrmCustomCommandUtility(aUtility);
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   474
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   475
	return customCommand;
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   476
	}
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   477
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   478
EXPORT_C CCustomCommandUtility* CCustomCommandUtility::NewL(CVideoPlayerUtility& aUtility)
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   479
	{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   480
	CCustomCommandUtility* customCommand;
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   481
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   482
	customCommand = new(ELeave) CVideoPlayerCustomCommandUtility(aUtility);
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   483
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   484
	return customCommand;
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   485
	}
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   486
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   487
EXPORT_C CCustomCommandUtility* CCustomCommandUtility::NewL(CVideoRecorderUtility& aUtility)
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   488
	{
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   489
	CCustomCommandUtility* customCommand;
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   490
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   491
	customCommand = new(ELeave) CVideoRecorderCustomCommandUtility(aUtility);
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   492
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   493
	return customCommand;
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   494
	}	
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   495
// ========================== OTHER EXPORTED FUNCTIONS =========================
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   496
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   497
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   498
b8ed18f6c07b 2010wk40
hgs
parents:
diff changeset
   499
// End of File