From fd5ba3b4b22e923cff11b65654e9b6f931ce9a3c Mon Sep 17 00:00:00 2001 From: Frank Reininghaus Date: Wed, 14 Aug 2013 23:44:57 +0200 Subject: Fix slow scrolling when hidden files or symbolic links are shown The problem was that we drawed the overlays using KIconLoader, which can be very slow, every time an item appeared on the screen. This commit makes sure that not only the icon, but the icon including overlays is cached in QPixmapCache. Therefore, the overlay drawing is done just once for each icon+overlays combination. For previews, the overlay drawing is done in KFileItemModelRolesUpdater just after the preview is received. BUG: 310662 BUG: 314339 FIXED-IN: 4.11.1 REVIEW: 111956 --- src/kitemviews/kstandarditemlistwidget.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/kitemviews/kstandarditemlistwidget.h') diff --git a/src/kitemviews/kstandarditemlistwidget.h b/src/kitemviews/kstandarditemlistwidget.h index ecf3a3b60..4bf6116fd 100644 --- a/src/kitemviews/kstandarditemlistwidget.h +++ b/src/kitemviews/kstandarditemlistwidget.h @@ -186,7 +186,7 @@ private: */ void closeRoleEditor(); - static QPixmap pixmapForIcon(const QString& name, int size); + static QPixmap pixmapForIcon(const QString& name, const QStringList& overlays, int size); /** * @return Preferred size of the rating-image based on the given -- cgit v1.3.1