Rotate the picture around -4 and 4 degrees.

This patch rotates the picture a bit, so it looks like it was
splattered around the profile.

Signed-off-by: Tomaz Canabrava <tomaz.canabrava@intel.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
Tomaz Canabrava 2014-06-08 13:40:19 -03:00 committed by Dirk Hohndel
parent c21122af40
commit 380385d86f

View file

@ -33,6 +33,12 @@ void DivePictureItem::setPixmap(const QPixmap &pix)
shadow->setZValue(-2);
setTransformOriginPoint(boundingRect().width()/2, boundingRect().height()/2);
qreal angle = qrand() % 5;
if (rand() % 2)
angle *= -1;
setRotation(angle);
}
void DivePictureItem::hoverEnterEvent(QGraphicsSceneHoverEvent *event)