summaryrefslogtreecommitdiffhomepage
path: root/ftnoir_posewidget
diff options
context:
space:
mode:
authorStanislaw Halik <sthalik@misaki.pl>2013-04-27 13:32:58 +0200
committerStanislaw Halik <sthalik@misaki.pl>2013-04-27 13:32:58 +0200
commit35a80d6757d5988749b4d5a07f4bf96ff02021ac (patch)
tree405deaa9c4424dec526ae901fbcdbbc32eda7d06 /ftnoir_posewidget
parent18f0c6cb3192dd996d6b5dd0e61dc6294fd92b45 (diff)
Don't repaint forcefully, there's no need
Diffstat (limited to 'ftnoir_posewidget')
-rw-r--r--ftnoir_posewidget/glwidget.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/ftnoir_posewidget/glwidget.cpp b/ftnoir_posewidget/glwidget.cpp
index 375cb97f..8f429df7 100644
--- a/ftnoir_posewidget/glwidget.cpp
+++ b/ftnoir_posewidget/glwidget.cpp
@@ -26,7 +26,7 @@ void GLWidget::paintEvent ( QPaintEvent * event ) {
QWidget::paintEvent(event);
QPainter p(this);
project_quad_texture();
- p.drawPixmap(QRect(0, 0, width(), height()), pixmap);
+ p.drawPixmap(event->rect(), pixmap);
}
void GLWidget::rotateBy(double xAngle, double yAngle, double zAngle)
@@ -48,7 +48,7 @@ void GLWidget::rotateBy(double xAngle, double yAngle, double zAngle)
matrix[2 * 3 + 0]= -sh*ca;
matrix[2 * 3 + 1]= sh*sa*cb + ch*sb;
matrix[2 * 3 + 2]= -sh*sa*sb + ch*cb;
- repaint();
+ update();
}
static __inline double dot(const Vec2f& p1, const Vec2f& p2) {