summaryrefslogtreecommitdiff
path: root/src/downloadlist.cpp
diff options
context:
space:
mode:
authorKrzysztof Starecki <krzysztof.starecki@gmail.com>2018-12-30 22:13:15 +0100
committerKrzysztof Starecki <krzysztof.starecki@gmail.com>2018-12-30 22:13:15 +0100
commitc11ff7e2db09514304cef35a650aa3fbef27dd16 (patch)
tree52a514445448ca847016e795da66ef7d099d313b /src/downloadlist.cpp
parentcfb941082e27925279535cade18d2b3c912c8930 (diff)
Add icon for incomplete download info, add download progress delegate
Diffstat (limited to 'src/downloadlist.cpp')
-rw-r--r--src/downloadlist.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/downloadlist.cpp b/src/downloadlist.cpp
index d78e97f9..09f6968c 100644
--- a/src/downloadlist.cpp
+++ b/src/downloadlist.cpp
@@ -21,6 +21,7 @@ along with Mod Organizer. If not, see <http://www.gnu.org/licenses/>.
#include "downloadmanager.h"
#include <QEvent>
#include <QColor>
+#include <QIcon>
#include <QSortFilterProxyModel>
@@ -147,6 +148,10 @@ QVariant DownloadList::data(const QModelIndex &index, int role) const
}
return text;
}
+ } else if (role == Qt::DecorationRole && index.column() == COL_NAME) {
+ if (!pendingDownload && m_Manager->getState(index.row()) >= DownloadManager::STATE_READY
+ && m_Manager->isInfoIncomplete(index.row()))
+ return QIcon(":/MO/gui/warning_16");
} else if (role == Qt::TextAlignmentRole) {
if (index.column() == COL_SIZE)
return Qt::AlignVCenter | Qt::AlignRight;