![]() |
Home · All Namespaces · All Classes |
#include <statusindicator.h>


Public Member Functions | |
| BatteryStatusIndicator (ApplicationContext &context, QGraphicsItem *parent=NULL) | |
| virtual | ~BatteryStatusIndicator () |
A status indicator for showing the battery charge level or battery charging animation.
Definition at line 192 of file statusindicator.h.
| BatteryStatusIndicator::BatteryStatusIndicator | ( | ApplicationContext & | context, | |
| QGraphicsItem * | parent = NULL | |||
| ) | [explicit] |
Constructs a BatteryStatusIndicator.
| context | the application context to get status information from | |
| parent | parent MWidget |
Definition at line 205 of file statusindicator.cpp.
:
StatusIndicator(parent)
{
setObjectName(QString(metaObject()->className()) + BATTERY_MODE_NORMAL);
batteryLevel = createContextItem(context, "Battery.ChargeBars");
connect(batteryLevel, SIGNAL(contentsChanged()), this, SLOT(batteryLevelChanged()));
batteryCharging = createContextItem(context, "Battery.IsCharging");
connect(batteryCharging, SIGNAL(contentsChanged()), this, SLOT(batteryChargingChanged()));
batterySaveMode = createContextItem(context, "System.PowerSaveMode");
connect(batterySaveMode, SIGNAL(contentsChanged()), this, SLOT(batteryChargingChanged()));
// Set the initial power save mode (in case it has been switched on before reboot, etc)
if (batterySaveMode->value().toBool()) {
setObjectName(QString(metaObject()->className()) + BATTERY_MODE_POWERSAVE);
}
batteryLevelChanged ();
}

| BatteryStatusIndicator::~BatteryStatusIndicator | ( | ) | [virtual] |
Definition at line 227 of file statusindicator.cpp.
{
}
| Copyright © 2010 Nokia Corporation | Generated on Thu Nov 4 2010 18:19:35 Doxygen 1.7.1 |
MeeGo Touch |