60
|
1 |
/*
|
|
2 |
*
|
|
3 |
* Copyright (c) <2010> Comarch S.A. and/or its subsidiary(-ies).
|
|
4 |
* All rights reserved.
|
|
5 |
* This component and the accompanying materials are made available
|
|
6 |
* under the terms of the License "Eclipse Public License v1.0"
|
|
7 |
* which accompanies this distribution, and is available
|
|
8 |
* at the URL "http://www.eclipse.org/legal/epl-v10.html".
|
|
9 |
*
|
|
10 |
* Original Contributors:
|
|
11 |
* Comarch S.A. - original contribution.
|
|
12 |
*
|
|
13 |
* Contributors:
|
|
14 |
*
|
|
15 |
* Description:
|
|
16 |
*
|
|
17 |
*/
|
|
18 |
|
|
19 |
#include <btdevice.h>
|
|
20 |
|
|
21 |
#include "hspcod.h"
|
|
22 |
#include "debug.h"
|
|
23 |
|
|
24 |
CHsHSPCoD* CHsHSPCoD::NewL()
|
|
25 |
{
|
|
26 |
|
|
27 |
CHsHSPCoD *self = CHsHSPCoD::NewLC();
|
|
28 |
CleanupStack::Pop( self );
|
|
29 |
|
|
30 |
return self;
|
|
31 |
}
|
|
32 |
|
|
33 |
CHsHSPCoD* CHsHSPCoD::NewLC()
|
|
34 |
{
|
|
35 |
CHsHSPCoD *self = new ( ELeave ) CHsHSPCoD;
|
|
36 |
CleanupStack::PushL( self );
|
|
37 |
self->ConstructL();
|
|
38 |
return self;
|
|
39 |
}
|
|
40 |
|
|
41 |
CHsHSPCoD::~CHsHSPCoD()
|
|
42 |
{
|
|
43 |
RestoreOldCod();
|
|
44 |
}
|
|
45 |
|
|
46 |
void CHsHSPCoD::ConstructL()
|
|
47 |
{
|
|
48 |
|
|
49 |
}
|
|
50 |
|
|
51 |
void CHsHSPCoD::SetNewCodL()
|
|
52 |
{
|
|
53 |
TRACE_FUNC_ENTRY
|
|
54 |
|
|
55 |
TBTDeviceClass newDeviceClass = TBTDeviceClass( KHsHSPDeviceClass );
|
|
56 |
TInt err = RProperty::Set( KPropertyUidBluetoothCategory,
|
|
57 |
KPropertyKeyBluetoothSetDeviceClass, newDeviceClass.DeviceClass() );
|
|
58 |
TRACE_INFO( (_L("error value = %d"), err) )
|
|
59 |
User::LeaveIfError( err );
|
|
60 |
|
|
61 |
TRACE_FUNC_EXIT
|
|
62 |
}
|