diff options
| author | Jeremy Rimpo <jeremy.rimpo@servermonkey.com> | 2023-09-23 21:02:52 -0500 |
|---|---|---|
| committer | Jeremy Rimpo <jeremy.rimpo@servermonkey.com> | 2023-09-23 21:02:52 -0500 |
| commit | 5d67b8dd212c235a452468dff5271880fb2d4ac3 (patch) | |
| tree | aa16829e8918bcc270ecbcfe87ef0dedb08392d4 | |
| parent | efdff42d5f6cdf5044e741ad7aa00bf73991c422 (diff) | |
Remove extraneous function
| -rw-r--r-- | src/downloadmanager.cpp | 15 | ||||
| -rw-r--r-- | src/downloadmanager.h | 8 |
2 files changed, 0 insertions, 23 deletions
diff --git a/src/downloadmanager.cpp b/src/downloadmanager.cpp index 6894b401..3f9a2a88 100644 --- a/src/downloadmanager.cpp +++ b/src/downloadmanager.cpp @@ -1327,21 +1327,6 @@ QString DownloadManager::getFileName(int index) const return m_ActiveDownloads.at(index)->m_FileName; } -int DownloadManager::getDownloadIndex(QString filename) const -{ - auto file = std::find_if(m_ActiveDownloads.begin(), m_ActiveDownloads.end(), - [=](DownloadManager::DownloadInfo* const val) { - if (val->m_FileName == filename) - return true; - return false; - }); - if (file != m_ActiveDownloads.end()) { - int fileIndex = m_ActiveDownloads.indexOf(*file); - return fileIndex; - } - return -1; -} - QDateTime DownloadManager::getFileTime(int index) const { if ((index < 0) || (index >= m_ActiveDownloads.size())) { diff --git a/src/downloadmanager.h b/src/downloadmanager.h index 618c2813..76e9ab5a 100644 --- a/src/downloadmanager.h +++ b/src/downloadmanager.h @@ -299,14 +299,6 @@ public: QString getFileName(int index) const; /** - * @brief retrieve the file index from the filename - * - * @param filename the filename of the download - * @return the index of the file - */ - int getDownloadIndex(QString filename) const; - - /** * @brief retrieve the file size of the download specified by index * * @param index index of the file to look up |
