diff options
author | Peter Yard <peter.yard@nokia.com> | 2011-01-27 10:18:09 +1000 |
---|---|---|
committer | Peter Yard <peter.yard@nokia.com> | 2011-01-27 10:18:09 +1000 |
commit | c1d6748a3e4f259a586dbe838ce7806e444b35cd (patch) | |
tree | 22c5ae4db76d2c6ef19360e216acb03bce85e821 /examples/sysinfo/dialog.cpp | |
parent | 6583b02888f311a6ce536d8a6cf10df0ceda7e28 (diff) |
Docs: change to snippets in SysInfo example.
Diffstat (limited to 'examples/sysinfo/dialog.cpp')
-rw-r--r-- | examples/sysinfo/dialog.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/examples/sysinfo/dialog.cpp b/examples/sysinfo/dialog.cpp index 91894fc9bc..9ce47e2c92 100644 --- a/examples/sysinfo/dialog.cpp +++ b/examples/sysinfo/dialog.cpp @@ -838,7 +838,9 @@ void Dialog::bluetoothChanged(bool b) void Dialog::setupBattery() { delete bi; + //! [batterystatus1] bi = new QSystemBatteryInfo(this); + //! [batterystatus1] connect(bi,SIGNAL(remainingCapacityPercentChanged(int)), this,SLOT(updateBatteryStatus(int))); @@ -868,10 +870,11 @@ void Dialog::setupBattery() connect(bi,SIGNAL(remainingChargingTimeChanged(int)), chargeTimelcdNumber,SLOT(display(int))); + //! [batterystatus2] chargerTypeChanged(bi->chargerType()); - currentBatStat = bi->batteryStatus(); + //! [batterystatus2] chargingStateChanged(bi->chargingState()); |