24
|
1 |
// Copyright (c) 2005-2009 Nokia Corporation and/or its subsidiary(-ies).
|
|
2 |
// All rights reserved.
|
|
3 |
// This component and the accompanying materials are made available
|
|
4 |
// under the terms of "Eclipse Public License v1.0"
|
|
5 |
// which accompanies this distribution, and is available
|
|
6 |
// at the URL "http://www.eclipse.org/legal/epl-v10.html".
|
|
7 |
//
|
|
8 |
// Initial Contributors:
|
|
9 |
// Nokia Corporation - initial contribution.
|
|
10 |
//
|
|
11 |
// Contributors:
|
|
12 |
//
|
|
13 |
// Description:
|
|
14 |
//
|
|
15 |
|
|
16 |
|
|
17 |
#ifndef __CBATTERYINFO_H__
|
|
18 |
#define __CBATTERYINFO_H__
|
|
19 |
|
|
20 |
#include <e32base.h>
|
|
21 |
#include <e32cons.h>
|
|
22 |
#include <e32def.h>
|
|
23 |
#include <etel3rdparty.h>
|
|
24 |
|
|
25 |
#include "CISVAPIAsync.h"
|
|
26 |
|
|
27 |
#include "CMainMenu.h"
|
|
28 |
|
|
29 |
/**
|
|
30 |
Retrieves the current state of the battery charge level
|
|
31 |
can be notified on change of battery status.
|
|
32 |
*/
|
|
33 |
class CBatteryInfo : public CISVAPIAsync
|
|
34 |
{
|
|
35 |
|
|
36 |
// Methods
|
|
37 |
public:
|
|
38 |
static CBatteryInfo* NewL(MExecAsync* aController);
|
|
39 |
~CBatteryInfo();
|
|
40 |
|
|
41 |
void DoStartRequestL();
|
|
42 |
void DoRequestNotificationL();
|
|
43 |
|
|
44 |
private:
|
|
45 |
CBatteryInfo(MExecAsync* aController);
|
|
46 |
void ConstructL();
|
|
47 |
|
|
48 |
void RunL();
|
|
49 |
void DoCancel();
|
|
50 |
|
|
51 |
// Data
|
|
52 |
public:
|
|
53 |
/**
|
|
54 |
Stores retrieved phone battery information.
|
|
55 |
*/
|
|
56 |
CTelephony::TBatteryInfoV1 iBatteryInfoV1;
|
|
57 |
|
|
58 |
private:
|
|
59 |
/**
|
|
60 |
Package iBatteryInfoV1.
|
|
61 |
*/
|
|
62 |
CTelephony::TBatteryInfoV1Pckg iBatteryInfoV1Pckg;
|
|
63 |
|
|
64 |
};
|
|
65 |
|
|
66 |
#endif // __CBATTERYINFO_H__
|