diff options
Diffstat (limited to 'examples/gestures/imagegestures/imagewidget.cpp')
-rw-r--r-- | examples/gestures/imagegestures/imagewidget.cpp | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/examples/gestures/imagegestures/imagewidget.cpp b/examples/gestures/imagegestures/imagewidget.cpp index c4a4e50..95525c5 100644 --- a/examples/gestures/imagegestures/imagewidget.cpp +++ b/examples/gestures/imagegestures/imagewidget.cpp @@ -43,6 +43,7 @@ #include <QtGui> +//! [constructor] ImageWidget::ImageWidget(QWidget *parent) : QWidget(parent), position(0), @@ -52,19 +53,15 @@ ImageWidget::ImageWidget(QWidget *parent) scaleFactor(1) { - setObjectName("ImageWidget"); setMinimumSize(QSize(100,100)); - setAttribute(Qt::WA_PaintOnScreen); - setAttribute(Qt::WA_OpaquePaintEvent); - setAttribute(Qt::WA_NoSystemBackground); - //! [enable gestures] grabGesture(Qt::PanGesture); grabGesture(Qt::PinchGesture); grabGesture(Qt::SwipeGesture); //! [enable gestures] } +//! [constructor] //! [event handler] bool ImageWidget::event(QEvent *event) |