revert r1171729, as those changes broke compilation on platforms where qreal != double
svn path=/trunk/KDE/kdelibs/; revision=1196092
This commit is contained in:
parent
31e2c5a0d4
commit
cf3951ad20
@ -257,7 +257,7 @@ int Animator::animateItem(QGraphicsItem *item, Animation animation)
|
||||
state->item = item;
|
||||
state->animation = animation;
|
||||
state->curve = d->driver->animationCurve(animation);
|
||||
state->frames = qMax(qreal(1.0), frames * (duration / 1000.0));
|
||||
state->frames = qMax(1.0, frames * (duration / 1000.0));
|
||||
state->currentFrame = 0;
|
||||
state->interval = d->driver->animationDuration(animation) / qreal(state->frames);
|
||||
state->interval = qMax(MIN_TICK_RATE_INT, state->interval - (state->interval % MIN_TICK_RATE_INT));
|
||||
@ -312,7 +312,7 @@ int Animator::moveItem(QGraphicsItem *item, Movement movement, const QPoint &des
|
||||
state->movement = movement;
|
||||
state->curve = d->driver->movementAnimationCurve(movement);
|
||||
int duration = d->driver->movementAnimationDuration(movement);
|
||||
state->frames = qMax(qreal(1.0), frames * (duration / 1000.0));
|
||||
state->frames = qMax(1.0, frames * (duration / 1000.0));
|
||||
state->currentFrame = 0;
|
||||
state->interval = duration / qreal(state->frames);
|
||||
state->interval = qMax(MIN_TICK_RATE_INT, state->interval - (state->interval % MIN_TICK_RATE_INT));
|
||||
@ -438,7 +438,7 @@ int Animator::animateElement(QGraphicsItem *item, Animation animation)
|
||||
state->item = item;
|
||||
state->curve = d->driver->elementAnimationCurve(animation);
|
||||
state->animation = animation;
|
||||
state->frames = qMax(qreal(1.0), frames * (duration / 1000.0));
|
||||
state->frames = qMax(1.0, frames * (duration / 1000.0));
|
||||
state->currentFrame = 0;
|
||||
state->interval = duration / qreal(state->frames);
|
||||
state->interval = qMax(MIN_TICK_RATE_INT, state->interval - (state->interval % MIN_TICK_RATE_INT));
|
||||
|
@ -236,7 +236,7 @@ void AppletHandle::paint(QPainter *painter, const QStyleOptionGraphicsItem *opti
|
||||
//kDebug() << "opaquePoint" << opaquePoint
|
||||
// << m_background->marginSize(LeftMargin) << m_decorationRect.width();
|
||||
g.setColorAt(0.0, Qt::transparent);
|
||||
g.setColorAt(qMax(qreal(0.0), opaquePoint - 0.05), Qt::transparent);
|
||||
g.setColorAt(qMax(0.0, opaquePoint - 0.05), Qt::transparent);
|
||||
g.setColorAt(opaquePoint, transparencyColor);
|
||||
g.setColorAt(1.0, transparencyColor);
|
||||
} else {
|
||||
|
Loading…
x
Reference in New Issue
Block a user