From 93b78e7c6135340484569a0310ca3dedceb47f31 Mon Sep 17 00:00:00 2001 From: Lars Knoll Date: Mon, 29 Aug 2016 10:29:47 +0200 Subject: Fix build with various features disabled Change-Id: I95cb3cf3434306344af3f4c7556f45dbfa0b08d6 Reviewed-by: Oswald Buddenhagen --- src/widgets/styles/qpixmapstyle.cpp | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src/widgets') diff --git a/src/widgets/styles/qpixmapstyle.cpp b/src/widgets/styles/qpixmapstyle.cpp index a0fff82dc0..ee5fd704dc 100644 --- a/src/widgets/styles/qpixmapstyle.cpp +++ b/src/widgets/styles/qpixmapstyle.cpp @@ -187,7 +187,9 @@ void QPixmapStyle::polish(QWidget *widget) view->setHorizontalScrollMode(QAbstractItemView::ScrollPerPixel); view->setVerticalScrollMode(QAbstractItemView::ScrollPerPixel); } +#if QT_CONFIG(gestures) QScroller::grabGesture(scrollArea->viewport(), QScroller::LeftMouseButtonGesture); +#endif } if (qobject_cast(widget)) @@ -217,8 +219,10 @@ void QPixmapStyle::unpolish(QWidget *widget) if (qstrcmp(widget->metaObject()->className(),"QComboBoxPrivateContainer") == 0) widget->removeEventFilter(this); +#if QT_CONFIG(gestures) if (QAbstractScrollArea *scrollArea = qobject_cast(widget)) QScroller::ungrabGesture(scrollArea->viewport()); +#endif QCommonStyle::unpolish(widget); } -- cgit v1.2.3