| 51 | } |
| 52 | |
| 53 | QStringList SendingHandler::getValidFilesFromArchive(const QString& archivePath) { |
| 54 | if (!m_tempDir.isValid()) { |
| 55 | QMessageBox::critical(Q_NULLPTR, tr("Transfer error"), tr("Could not create the temporary directory to extract the archive.\nFile: ") + archivePath); |
| 56 | return {}; |
| 57 | } |
| 58 | |
| 59 | bundleList.clear(); |
| 60 | extractor(archivePath.toStdString().c_str(), m_tempDir.path().toStdString().c_str(), checkValidFile); |
| 61 | // TODO: check bundleList size, alert if 0 |
| 62 | return bundleList; |
| 63 | } |
| 64 | |
| 65 | SendingHandler::SendingHandler(QObject *parent, QPushButton *cancelBtn, QProgressBar *bar, QTableWidget *table) : QObject{parent} { |
| 66 | m_progressBar = bar; |