Code adaptation because of changes on libraries related to revision 719630

svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=719642
This commit is contained in:
Rafael Fernández López 2007-10-01 15:09:41 +00:00
parent 4040f40aaa
commit 0f7e4e52ab
2 changed files with 3 additions and 4 deletions

View File

@ -751,7 +751,7 @@ void Applet::paintWidget(QPainter *painter, const QStyleOptionGraphicsItem *opti
//TODO: make pretty.
painter->setBrush(QBrush(color(), Qt::SolidPattern));
painter->drawRoundRect(boundingRect());
int iconDim = KIconLoader::global()->currentSize(K3Icon::Desktop);
int iconDim = KIconLoader::global()->currentSize(KIconLoader::Desktop);
qreal midX = (boundingRect().width() / 2) - (iconDim / 2);
qreal midY = (boundingRect().height() / 2) - (iconDim / 2);
KIcon ico(icon());

View File

@ -40,7 +40,6 @@
#include <KIconEffect>
#include <KIconLoader>
#include <KIcon>
#include <K3Icon>
#include <KUrl>
#include <KRun>
#include <KMimeType>
@ -535,8 +534,8 @@ QPixmap Icon::Private::decoration(const QStyleOptionGraphicsItem *option) const
// Note that in KIconLoader terminology, active = hover.
// ### We're assuming that the icon group is desktop/filemanager, since this
// is KFileItemDelegate.
if (effect->hasEffect(K3Icon::Desktop, K3Icon::ActiveState)) {
result = effect->apply(result, K3Icon::Desktop, K3Icon::ActiveState);
if (effect->hasEffect(KIconLoader::Desktop, KIconLoader::ActiveState)) {
result = effect->apply(result, KIconLoader::Desktop, KIconLoader::ActiveState);
}
}
}