fixed repeated handling of the critical capacity event
[qbat.git] / batteryicon.h
blob8fb1642b605da8ae30d33b339f227758d0674829
1 //
2 // C++ Interface: batteryicon
3 //
4 // Author: Oliver Groß <z.o.gross@gmx.de>, (C) 2008
5 //
6 // Copyright: See COPYING file that comes with this distribution
7 //
8 #ifndef QBAT_BATTERYICON_H
9 #define QBAT_BATTERYICON_H
11 #include <QSystemTrayIcon>
13 namespace qbat {
14 class Settings;
16 class CBatteryIcon : public QSystemTrayIcon {
17 Q_OBJECT
18 private:
19 QString m_BatteryName;
20 QPixmap m_Icon;
21 Settings * m_Settings;
22 public:
23 CBatteryIcon(QString batteryName, Settings * settings, QMenu * contextMenu, QObject * parent = 0);
24 ~CBatteryIcon();
26 QString batteryName() const { return m_BatteryName; }
28 void updateData(int chargeFull, int chargeFullDesign, int chargeNow, int currentNow, int status);
32 #endif