修改不传ng文件夹下的图片以及相机掉电以后定时器到时间继续传送未发送的图片

CigaretteSH
Flamingo 9 months ago
parent 8b7f95fbad
commit 9dcfd050a6

@ -325,7 +325,7 @@ void ExportDataThread::run()
}
}
if (b_quit && (!tmpListToZip.isEmpty())) {
if ((b_quit || (!timer->isActive() && !readyToSendZip)) && (!tmpListToZip.isEmpty())) {
listToZip += tmpListToZip;
tmpListToZip.clear();
readyToSendZip = true;
@ -403,6 +403,7 @@ void ExportDataThread::run()
}
fileNg.remove();
fileOk.remove();
listToZip.clear();
readyToSendZip = false;
}
}
@ -505,20 +506,23 @@ void ExportDataThread::GetDataFromSaveThread(QString filePath) {
QString remotePath;
if (timer->isActive()) {
if ((filePath.indexOf("ng_result") != -1) || (filePath.indexOf("ng") == -1)) {
if (filePath.indexOf("ng") == -1) {
tmpListToZip.append(filePath);
}
}
else {
if (!tmpListToZip.isEmpty()) {
listToZip = tmpListToZip;
tmpListToZip.clear();
if ((filePath.indexOf("ng_result") != -1) || (filePath.indexOf("ng") == -1)) {
tmpListToZip.append(filePath);
}
if (!listToZip.isEmpty()) {
readyToSendZip = true;
}
if (filePath.indexOf("ng") == -1) {
tmpListToZip.append(filePath);
}
//remotePath = filePath.mid(filePath.indexOf("image") - 1);
//ConnectServer(filePath, remotePath);
timer->start(1000 * 60 * 5); // 5min

Loading…
Cancel
Save