We are calling that every time we draw the folder delegate.
Which is a lot when the sync is runing and the progress bar is moving
flavor = QLatin1String("colored");
}
- if( QIcon::hasThemeIcon( name )) {
- // use from theme
- return QIcon::fromTheme( name );
- }
-
QString key = name + "," + flavor;
QIcon & cached = _iconCache[key];
if (cached.isNull()) {
+ if(QIcon::hasThemeIcon(name)) {
+ // use from theme
+ return cached = QIcon::fromTheme(name);
+ }
+
QList<int> sizes;
sizes <<16 << 22 << 32 << 48 << 64 << 128 << 256;
foreach (int size, sizes) {