make the colorization effect more noticeable, which in turn makes it feel smoother.
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=761575
This commit is contained in:
parent
47fbc5aa5a
commit
6a26e85e1a
@ -131,14 +131,14 @@ void DesktopToolbox::paint(QPainter *painter, const QStyleOptionGraphicsItem *op
|
|||||||
|
|
||||||
const qreal progress = m_animFrame / m_size;
|
const qreal progress = m_animFrame / m_size;
|
||||||
|
|
||||||
if (progress > 0.1) {
|
if (progress <= 0.9) {
|
||||||
m_icon.paint(painter, QRect(m_size*2 - 34, 2, 32, 32));
|
m_icon.paint(painter, QRect(m_size*2 - 34, 2, 32, 32), Qt::AlignCenter, QIcon::Disabled, QIcon::Off);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (progress <= 0.9) {
|
if (progress > 0.1) {
|
||||||
painter->save();
|
painter->save();
|
||||||
painter->setOpacity(1 - progress);
|
painter->setOpacity(progress);
|
||||||
m_icon.paint(painter, QRect(m_size*2 - 34, 2, 32, 32), Qt::AlignCenter, QIcon::Disabled, QIcon::Off);
|
m_icon.paint(painter, QRect(m_size*2 - 34, 2, 32, 32));
|
||||||
painter->restore();
|
painter->restore();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user