From 49e1dd23b699b499d9b715ef74cb7ca5b0189584 Mon Sep 17 00:00:00 2001 From: Tannin Date: Sat, 31 Aug 2013 17:11:17 +0200 Subject: - mod list can now be sorted by install time - the sorting of download archives wasn't actually by index instead of file time - bugfix: some of the plugins crashed if they failed to create a mod --- src/downloadmanager.h | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'src/downloadmanager.h') diff --git a/src/downloadmanager.h b/src/downloadmanager.h index 01d45582..92ba3143 100644 --- a/src/downloadmanager.h +++ b/src/downloadmanager.h @@ -83,6 +83,7 @@ private: QFile m_Output; QNetworkReply *m_Reply; QTime m_StartTime; + qint64 m_PreResumeSize; int m_Progress; int m_ModID; int m_FileID; @@ -91,6 +92,9 @@ private: QStringList m_Urls; qint64 m_ResumePos; qint64 m_TotalSize; + + QDateTime m_Created; // used as a cache in DownloadManager::getFileTime, may not be valid elsewhere + int m_Tries; bool m_ReQueried; @@ -215,6 +219,13 @@ public: */ qint64 getFileSize(int index) const; + /** + * @brief retrieve the creation time of the download specified by index + * @param index index of the file to look up + * @return size of the file (total size during download) + */ + QDateTime getFileTime(int index) const; + /** * @brief retrieve the current progress of the download specified by index * @@ -298,6 +309,7 @@ public: int indexByName(const QString &fileName) const; void pauseAll(); + signals: void aboutToUpdate(); -- cgit v1.3.1