diff options
| author | Peter Penz <[email protected]> | 2008-08-22 21:14:39 +0000 |
|---|---|---|
| committer | Peter Penz <[email protected]> | 2008-08-22 21:14:39 +0000 |
| commit | aa3e271ce39e7cbbd546d5f9197a1f83ba53fcde (patch) | |
| tree | a6668d22f903ed355b572fe4f9c3b2dab9c1fbf7 | |
| parent | cd3e667e9c29d848f1a21fb37b1182adceeab27d (diff) | |
* convert the size in bytes to larger unit
* minor style fix
svn path=/trunk/KDE/kdebase/apps/; revision=851088
| -rw-r--r-- | src/statusbarspaceinfo.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/statusbarspaceinfo.cpp b/src/statusbarspaceinfo.cpp index dafd8517c..a311902f7 100644 --- a/src/statusbarspaceinfo.cpp +++ b/src/statusbarspaceinfo.cpp @@ -68,9 +68,7 @@ void StatusBarSpaceInfo::refresh() } KDiskFreeSpaceInfo job = KDiskFreeSpaceInfo::freeSpaceInfo(mp->mountPoint()); - - if(!job.isValid()) - { + if (!job.isValid()) { setText(i18nc("@info:status", "Unknown size")); setValue(0); update(); @@ -82,7 +80,9 @@ void StatusBarSpaceInfo::refresh() const bool valuesChanged = (kBUsed != static_cast<quint64>(value())) || (kBSize != m_kBSize); if (valuesChanged) { - setText(i18nc("@info:status Free disk space", "%1 free", job.available())); + setText(i18nc("@info:status Free disk space", "%1 free", + KIO::convertSize(job.available()))); + setUpdatesEnabled(false); m_kBSize = kBSize; setValue(kBSize > 0 ? (kBUsed * 100) / kBSize : 0); |
