summaryrefslogtreecommitdiffstats
path: root/examples
diff options
context:
space:
mode:
authorRichard Moe Gustavsen <richard.gustavsen@nokia.com>2009-09-21 11:35:35 (GMT)
committerRichard Moe Gustavsen <richard.gustavsen@nokia.com>2009-09-21 11:36:32 (GMT)
commite39d9914491c4a21f7c44140a26fc9bdff682b9d (patch)
treeb6e0f63891d06e681aa44a4c062059349b560ca4 /examples
parent5dbd70c6bf294f85663f1c0f809afab73fea2500 (diff)
downloadQt-e39d9914491c4a21f7c44140a26fc9bdff682b9d.zip
Qt-e39d9914491c4a21f7c44140a26fc9bdff682b9d.tar.gz
Qt-e39d9914491c4a21f7c44140a26fc9bdff682b9d.tar.bz2
Fix signal/slot connection bug
A signal was renamed. Update the example to reflect this. Rev-By: Trustme. Example fix only.
Diffstat (limited to 'examples')
-rw-r--r--examples/gestures/imageviewer/imagewidget.cpp9
1 files changed, 2 insertions, 7 deletions
diff --git a/examples/gestures/imageviewer/imagewidget.cpp b/examples/gestures/imageviewer/imagewidget.cpp
index e17d746..2be6cc5 100644
--- a/examples/gestures/imageviewer/imagewidget.cpp
+++ b/examples/gestures/imageviewer/imagewidget.cpp
@@ -62,13 +62,13 @@ ImageWidget::ImageWidget(QWidget *parent)
QGesture *panGesture = new QPanGesture(this);
connect(panGesture, SIGNAL(started()), this, SLOT(panTriggered()));
connect(panGesture, SIGNAL(finished()), this, SLOT(panTriggered()));
- connect(panGesture, SIGNAL(cancelled()), this, SLOT(panTriggered()));
+ connect(panGesture, SIGNAL(canceled()), this, SLOT(panTriggered()));
connect(panGesture, SIGNAL(triggered()), this, SLOT(panTriggered()));
QGesture *pinchGesture = new QPinchGesture(this);
connect(pinchGesture, SIGNAL(started()), this, SLOT(pinchTriggered()));
connect(pinchGesture, SIGNAL(finished()), this, SLOT(pinchTriggered()));
- connect(pinchGesture, SIGNAL(cancelled()), this, SLOT(pinchTriggered()));
+ connect(pinchGesture, SIGNAL(canceled()), this, SLOT(pinchTriggered()));
connect(pinchGesture, SIGNAL(triggered()), this, SLOT(pinchTriggered()));
//! [construct swipe gesture]
@@ -138,11 +138,6 @@ void ImageWidget::pinchTriggered()
void ImageWidget::swipeTriggered()
{
QSwipeGesture *pg = qobject_cast<QSwipeGesture*>(sender());
-//! [swipe slot start]
- qDebug() << (int) pg->horizontalDirection();
- qDebug() << pg->swipeAngle();
-
-//! [swipe slot finish]
if (pg->horizontalDirection() == QSwipeGesture::Left
|| pg->verticalDirection() == QSwipeGesture::Up)
goPrevImage();