summaryrefslogtreecommitdiff
path: root/noncore/settings/aqpkg/installdlgimpl.cpp
Unidiff
Diffstat (limited to 'noncore/settings/aqpkg/installdlgimpl.cpp') (more/less context) (show whitespace changes)
-rw-r--r--noncore/settings/aqpkg/installdlgimpl.cpp4
1 files changed, 1 insertions, 3 deletions
diff --git a/noncore/settings/aqpkg/installdlgimpl.cpp b/noncore/settings/aqpkg/installdlgimpl.cpp
index 17f7b08..ea2c47f 100644
--- a/noncore/settings/aqpkg/installdlgimpl.cpp
+++ b/noncore/settings/aqpkg/installdlgimpl.cpp
@@ -385,29 +385,27 @@ void InstallDlgImpl :: displayAvailableSpace( const QString &text )
385 385
386 long blockSize = 0; 386 long blockSize = 0;
387 long totalBlocks = 0; 387 long totalBlocks = 0;
388 long availBlocks = 0; 388 long availBlocks = 0;
389 QString space; 389 QString space;
390 if ( Utils::getStorageSpace( (const char *)destDir, &blockSize, &totalBlocks, &availBlocks ) ) 390 if ( Utils::getStorageSpace( (const char *)destDir, &blockSize, &totalBlocks, &availBlocks ) )
391 { 391 {
392 long mult = blockSize / 1024; 392 long mult = blockSize / 1024;
393 long div = 1024 / blockSize; 393 long div = 1024 / blockSize;
394 394
395 if ( !mult ) mult = 1; 395 if ( !mult ) mult = 1;
396 if ( !div ) div = 1; 396 if ( !div ) div = 1;
397// long total = totalBlocks * mult / div;
398 long avail = availBlocks * mult / div; 397 long avail = availBlocks * mult / div;
399// long used = total - avail;
400 398
401 space.sprintf( "%ld Kb", avail ); 399 space = tr( "%1 Kb" ).arg( avail );
402 } 400 }
403 else 401 else
404 space = tr( "Unknown" ); 402 space = tr( "Unknown" );
405 403
406 if ( txtAvailableSpace ) 404 if ( txtAvailableSpace )
407 txtAvailableSpace->setText( space ); 405 txtAvailableSpace->setText( space );
408} 406}
409 407
410void InstallDlgImpl :: ipkgFinished() 408void InstallDlgImpl :: ipkgFinished()
411{ 409{
412 InstallData *item; 410 InstallData *item;
413 if ( firstPackage ) 411 if ( firstPackage )