diff options
| author | Tannin <devnull@localhost> | 2015-03-09 12:34:34 +0100 |
|---|---|---|
| committer | Tannin <devnull@localhost> | 2015-03-09 12:34:34 +0100 |
| commit | 7a1ae9b0f1560c9eda32e032796fbb3fd56ff236 (patch) | |
| tree | dea71435ac1042cb008fcd9f7b1ec57e6ea91227 /src/genericicondelegate.cpp | |
| parent | d45ebf134819e1559718681becca9c4139fb7151 (diff) | |
| parent | db2954e8eb41da715b9e7d79a72e225797401413 (diff) | |
Merge with branch1.2
Diffstat (limited to 'src/genericicondelegate.cpp')
| -rw-r--r-- | src/genericicondelegate.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/genericicondelegate.cpp b/src/genericicondelegate.cpp index c3471735..3711b428 100644 --- a/src/genericicondelegate.cpp +++ b/src/genericicondelegate.cpp @@ -1,6 +1,7 @@ #include "genericicondelegate.h"
#include "pluginlist.h"
#include <QList>
+#include <QPixmapCache>
GenericIconDelegate::GenericIconDelegate(QObject *parent, int role, int logicalIndex, int compactSize)
@@ -19,14 +20,13 @@ void GenericIconDelegate::columnResized(int logicalIndex, int, int newSize) }
}
-QList<QIcon> GenericIconDelegate::getIcons(const QModelIndex &index) const
+QList<QString> GenericIconDelegate::getIcons(const QModelIndex &index) const
{
- QList<QIcon> result;
+ QList<QString> result;
if (index.isValid()) {
foreach (const QVariant &var, index.data(m_Role).toList()) {
- QIcon icon = var.value<QIcon>();
- if (!m_Compact || !icon.isNull()) {
- result.append(icon);
+ if (!m_Compact || !var.toString().isEmpty()) {
+ result.append(var.toString());
}
}
}
|
