-rw-r--r-- | core/launcher/launcherview.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/core/launcher/launcherview.cpp b/core/launcher/launcherview.cpp index 047fe45..c2bde53 100644 --- a/core/launcher/launcherview.cpp +++ b/core/launcher/launcherview.cpp @@ -682,49 +682,49 @@ void LauncherView::setBackgroundType( BackgroundType t, const QString &val ) painter.end(); bgCache->insert( bgName, new BgPixmap(bg) ); } icons->setBackgroundPixmap( bg ); break; } case SolidColor: icons->setBackgroundPixmap( QPixmap() ); if ( val.isEmpty() ) { icons->setBackgroundColor( colorGroup().base() ); } else { icons->setBackgroundColor( val ); } bgName = ""; break; case Image: bgName = val; if ( bgCache->contains( bgName ) ) { (*bgCache)[bgName]->ref++; icons->setBackgroundPixmap( (*bgCache)[bgName]->pm ); } else { qDebug( "Loading image: %s", val.latin1() ); - QPixmap bg( Resource::loadPixmap( "wallpaper/" + val ) ); + QPixmap bg( Resource::loadPixmap( val ) ); if ( bg.isNull() ) { QImageIO imgio; imgio.setFileName( bgName ); QSize ds = qApp->desktop()->size(); QString param( "Scale( %1, %2, ScaleMin )" ); // No tr imgio.setParameters( param.arg(ds.width()).arg(ds.height()).latin1() ); imgio.read(); bg = imgio.image(); } bgCache->insert( bgName, new BgPixmap(bg) ); icons->setBackgroundPixmap( bg ); } break; } // remove unreferenced backgrounds. QMap<QString,BgPixmap*>::Iterator it = bgCache->begin(); while ( it != bgCache->end() ) { QMap<QString,BgPixmap*>::Iterator curr = it; ++it; if ( (*curr)->ref == 0 ) { delete (*curr); bgCache->remove( curr ); } |