Use the first thumbnail as icon for KNS resources

Rather than using the same icon for all KNS based
resources, this will return the URL for the first
screenshot item.

BUG: 360675
Differential Revision:
parent e9294a66
......@@ -60,7 +60,8 @@ KNSBackend * KNSResource::knsBackend() const
QVariant KNSResource::icon() const
return knsBackend()->iconName();
const QString thumbnail = m_entry.previewUrl(KNSCore::EntryInternal::PreviewSmall1);
return thumbnail.isEmpty() ? knsBackend()->iconName() : m_entry.previewUrl(KNSCore::EntryInternal::PreviewSmall1);
QString KNSResource::comment()
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment