mirror of
https://port.numenaute.org/aleajactaest/khanat-opennel-code.git
synced 2024-11-29 23:26:00 +00:00
Fixed: Wrong size for downloaded components
--HG-- branch : develop
This commit is contained in:
parent
7d7ce29894
commit
72144c3131
1 changed files with 18 additions and 1 deletions
|
@ -265,7 +265,24 @@ void CUninstallDialog::updateSizes()
|
|||
}
|
||||
|
||||
// downloaded files
|
||||
qint64 bytes = getDirectorySize(config->getInstallationDirectory(), false);
|
||||
qint64 bytes = 0;
|
||||
|
||||
QDir dir(config->getInstallationDirectory());
|
||||
|
||||
QStringList filters;
|
||||
|
||||
filters << "*.log";
|
||||
filters << "*.7z";
|
||||
filters << "*.bnp";
|
||||
filters << "*.zip";
|
||||
filters << "*.part";
|
||||
|
||||
QFileInfoList downloadedFiles = dir.entryInfoList(filters, QDir::Files);
|
||||
|
||||
foreach(const QFileInfo &info, downloadedFiles)
|
||||
{
|
||||
bytes += info.size();
|
||||
}
|
||||
|
||||
emit updateSize(m_downloadedFilesIndex, qBytesToHumanReadable(bytes));
|
||||
|
||||
|
|
Loading…
Reference in a new issue