mirror of
https://gitea.msk.dinamika-avia.ru/Constanta-Design/RRJServer.git
synced 2026-03-28 19:55:48 +03:00
bugfix: loading process disable
This commit is contained in:
@@ -357,57 +357,6 @@ QList<FileData>* UpdateController::calculateHash(QString path)
|
||||
}
|
||||
}
|
||||
serverDataList.append(*files);
|
||||
|
||||
// QDirIterator iterator(path,QDirIterator::Subdirectories);
|
||||
// QDir dir(path);
|
||||
// dir.setFilter(QDir::NoDotAndDotDot);
|
||||
|
||||
// while (iterator.hasNext())
|
||||
// {
|
||||
// iterator.next();
|
||||
// QFileInfo fileInfo = iterator.fileInfo();
|
||||
// FileData currentFile;
|
||||
// QFile file(fileInfo.absoluteFilePath());
|
||||
|
||||
// quint64 fileSize = file.size();
|
||||
// const quint64 bufferSize = 10240;
|
||||
|
||||
// if (fileInfo.isHidden()) continue;
|
||||
|
||||
// if(fileInfo.isFile() && file.open(QIODevice::ReadOnly) && !fileInfo.fileName().contains(".meta"))
|
||||
// {
|
||||
// char buffer[bufferSize];
|
||||
// int bytesRead;
|
||||
// int readSize = qMin(fileSize,bufferSize);
|
||||
|
||||
// QCryptographicHash hash(QCryptographicHash::Md5);
|
||||
// while(readSize > 0 && (bytesRead = file.read(buffer,readSize)) > 0){
|
||||
// fileSize -= bytesRead;
|
||||
// hash.addData(buffer,bytesRead);
|
||||
// readSize = qMin(fileSize,bufferSize);
|
||||
// }
|
||||
|
||||
// hashString = QString(hash.result().toHex());
|
||||
// currentFile.hash = hashString;
|
||||
// currentFile.path = Tools::createLocalPath(fileInfo.absoluteFilePath());
|
||||
|
||||
// files->push_back(currentFile);
|
||||
// file.close();
|
||||
|
||||
// }
|
||||
// else if(fileInfo.isDir() && fileInfo.fileName() != ".." && !fileInfo.isRoot())
|
||||
// {
|
||||
// currentFile.hash = "FOLDER";
|
||||
// currentFile.path = Tools::createLocalPath(fileInfo.path());
|
||||
|
||||
// if(!files->contains(currentFile)){
|
||||
// files->push_back(currentFile);
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
|
||||
// std::sort(files->begin(),files->end());
|
||||
//
|
||||
return files;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user