225 // ----------------------------------------------------------------------------- |
225 // ----------------------------------------------------------------------------- |
226 void PartDownloader::downloadFile (str dest, str url, bool primary) |
226 void PartDownloader::downloadFile (str dest, str url, bool primary) |
227 { const int row = ui->progress->rowCount(); |
227 { const int row = ui->progress->rowCount(); |
228 |
228 |
229 // Don't download files repeadetly. |
229 // Don't download files repeadetly. |
230 if (m_filesToDownload.find (dest) != -1u) |
230 if (m_filesToDownload.indexOf (dest) != -1) |
231 return; |
231 return; |
232 |
232 |
233 modifyDest (dest); |
233 modifyDest (dest); |
234 print ("DOWNLOAD: %1 -> %2\n", url, PartDownloader::getDownloadPath() + DIRSLASH + dest); |
234 print ("DOWNLOAD: %1 -> %2\n", url, PartDownloader::getDownloadPath() + DIRSLASH + dest); |
235 PartDownloadRequest* req = new PartDownloadRequest (url, dest, primary, this); |
235 PartDownloadRequest* req = new PartDownloadRequest (url, dest, primary, this); |