Commit 5ccdf24b authored by Nicolas Fella's avatar Nicolas Fella Committed by Stefano Crocco
Browse files

Port away from KIconLoader::loadMimeTypeIcon

It's semi-deprecated.
parent 25a8994a
......@@ -404,7 +404,8 @@ QPixmap Inode::pixmap(int i) const
if (!_mimePixmapSet) {
QUrl u = QUrl::fromLocalFile(path());
_mimePixmap = KIconLoader::global()->loadMimeTypeIcon(KIO::iconNameForUrl(u), KIconLoader::Small);
const QIcon icon = QIcon::fromTheme(KIO::iconNameForUrl(u), QIcon::fromTheme(QStringLiteral("application-octet-stream")));
_mimePixmap = icon.pixmap(KIconLoader::SizeSmall);
_mimePixmapSet = true;
}
return _mimePixmap;
......
......@@ -59,7 +59,8 @@ void KonqDraggableLabel::mouseMoveEvent(QMouseEvent *ev)
drag->setMimeData(md);
QString iconName = KIO::iconNameForUrl(lst.first());
drag->setPixmap(KIconLoader::global()->loadMimeTypeIcon(iconName, KIconLoader::Small));
const QIcon icon = QIcon::fromTheme(iconName, QIcon::fromTheme(QStringLiteral("application-octet-stream")));
drag->setPixmap(icon.pixmap(KIconLoader::SizeSmall));
drag->exec();
}
......
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