| 156 | } |
| 157 | |
| 158 | void SendingHandler::linkProgress(int value, int total) { |
| 159 | if (total) { |
| 160 | if (m_progressBar) { |
| 161 | m_progressBar->setMaximum(total); |
| 162 | m_progressBar->setValue(value); |
| 163 | } |
| 164 | if (value != total) { |
| 165 | return; |
| 166 | } |
| 167 | } else { |
| 168 | switch (value) { |
| 169 | default: |
| 170 | QMessageBox::warning(Q_NULLPTR, QObject::tr("Transfer issue"), QObject::tr("Transfer issue, see console for information.")); |
| 171 | break; |
| 172 | } |
| 173 | } |
| 174 | guiDelay(100); |
| 175 | if (m_progressBar) { |
| 176 | m_progressBar->setVisible(false); |
| 177 | m_btnCancelTransfer->setVisible(false); |
| 178 | m_progressBar->setValue(0); |
| 179 | } |
| 180 | guiSend = false; |
| 181 | emit sendFinished(); |
| 182 | } |
| 183 | |
| 184 | void SendingHandler::addFile(const QString &file, bool select) { |
| 185 | int j, rows = m_table->rowCount(); |
nothing calls this directly
no test coverage detected