summaryrefslogtreecommitdiffstats
path: root/src/gui/kernel
diff options
context:
space:
mode:
authorStephan Binner <stephan.binner@basyskom.com>2017-05-30 22:22:22 +0200
committerStephan Binner <stephan.binner@basyskom.com>2017-06-28 16:15:09 +0000
commit5ede5706a8b8052280981aa1d9c42999a24b74b5 (patch)
tree93240295ca4f9e21f3ce6c74748f04697c060c67 /src/gui/kernel
parentfdbf400b27ff25f98a64879adeeb342931a84d9a (diff)
Convert features.wheelevent to QT_CONFIG
Change-Id: I46083a9115c199d1ebe024ed5f64b160a27462f1 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
Diffstat (limited to 'src/gui/kernel')
-rw-r--r--src/gui/kernel/qevent.cpp8
-rw-r--r--src/gui/kernel/qevent.h2
-rw-r--r--src/gui/kernel/qguiapplication.cpp4
-rw-r--r--src/gui/kernel/qwindow.cpp6
-rw-r--r--src/gui/kernel/qwindow.h4
5 files changed, 12 insertions, 12 deletions
diff --git a/src/gui/kernel/qevent.cpp b/src/gui/kernel/qevent.cpp
index 2777e408c1..12ac7323a6 100644
--- a/src/gui/kernel/qevent.cpp
+++ b/src/gui/kernel/qevent.cpp
@@ -767,7 +767,7 @@ QHoverEvent::~QHoverEvent()
\sa pos(), pixelDelta(), angleDelta()
*/
-#ifndef QT_NO_WHEELEVENT
+#if QT_CONFIG(wheelevent)
QWheelEvent::QWheelEvent(const QPointF &pos, int delta,
Qt::MouseButtons buttons, Qt::KeyboardModifiers modifiers,
Qt::Orientation orient)
@@ -952,7 +952,7 @@ QWheelEvent::QWheelEvent(const QPointF &pos, const QPointF& globalPos,
invertedScrolling(inverted)
{}
-#endif // QT_NO_WHEELEVENT
+#endif // QT_CONFIG(wheelevent)
/*!
\fn QPoint QWheelEvent::pixelDelta() const
@@ -3956,13 +3956,13 @@ QDebug operator<<(QDebug dbg, const QEvent *e)
dbg << ')';
}
break;
-# ifndef QT_NO_WHEELEVENT
+# if QT_CONFIG(wheelevent)
case QEvent::Wheel: {
const QWheelEvent *we = static_cast<const QWheelEvent *>(e);
dbg << "QWheelEvent(" << "pixelDelta=" << we->pixelDelta() << ", angleDelta=" << we->angleDelta() << ')';
}
break;
-# endif // !QT_NO_WHEELEVENT
+# endif // QT_CONFIG(wheelevent)
case QEvent::KeyPress:
case QEvent::KeyRelease:
case QEvent::ShortcutOverride:
diff --git a/src/gui/kernel/qevent.h b/src/gui/kernel/qevent.h
index cfc3b842d7..95de600012 100644
--- a/src/gui/kernel/qevent.h
+++ b/src/gui/kernel/qevent.h
@@ -169,7 +169,7 @@ protected:
QPointF p, op;
};
-#ifndef QT_NO_WHEELEVENT
+#if QT_CONFIG(wheelevent)
class Q_GUI_EXPORT QWheelEvent : public QInputEvent
{
public:
diff --git a/src/gui/kernel/qguiapplication.cpp b/src/gui/kernel/qguiapplication.cpp
index c0b0acbda6..8cbf0a457d 100644
--- a/src/gui/kernel/qguiapplication.cpp
+++ b/src/gui/kernel/qguiapplication.cpp
@@ -1997,7 +1997,7 @@ void QGuiApplicationPrivate::processMouseEvent(QWindowSystemInterfacePrivate::Mo
void QGuiApplicationPrivate::processWheelEvent(QWindowSystemInterfacePrivate::WheelEvent *e)
{
-#ifndef QT_NO_WHEELEVENT
+#if QT_CONFIG(wheelevent)
QWindow *window = e->window.data();
QPointF globalPoint = e->globalPos;
QPointF localPoint = e->localPos;
@@ -2027,7 +2027,7 @@ void QGuiApplicationPrivate::processWheelEvent(QWindowSystemInterfacePrivate::Wh
QGuiApplication::sendSpontaneousEvent(window, &ev);
#else
Q_UNUSED(e);
-#endif /* ifndef QT_NO_WHEELEVENT */
+#endif // QT_CONFIG(wheelevent)
}
// Remember, Qt convention is: keyboard state is state *before*
diff --git a/src/gui/kernel/qwindow.cpp b/src/gui/kernel/qwindow.cpp
index 519d749b8a..8048a397e8 100644
--- a/src/gui/kernel/qwindow.cpp
+++ b/src/gui/kernel/qwindow.cpp
@@ -2220,7 +2220,7 @@ bool QWindow::event(QEvent *ev)
#endif
break; }
-#ifndef QT_NO_WHEELEVENT
+#if QT_CONFIG(wheelevent)
case QEvent::Wheel:
wheelEvent(static_cast<QWheelEvent*>(ev));
break;
@@ -2418,7 +2418,7 @@ void QWindow::mouseMoveEvent(QMouseEvent *ev)
ev->ignore();
}
-#ifndef QT_NO_WHEELEVENT
+#if QT_CONFIG(wheelevent)
/*!
Override this to handle mouse wheel or other wheel events (\a ev).
*/
@@ -2426,7 +2426,7 @@ void QWindow::wheelEvent(QWheelEvent *ev)
{
ev->ignore();
}
-#endif //QT_NO_WHEELEVENT
+#endif // QT_CONFIG(wheelevent)
/*!
Override this to handle touch events (\a ev).
diff --git a/src/gui/kernel/qwindow.h b/src/gui/kernel/qwindow.h
index 2883749d2e..748c3ee707 100644
--- a/src/gui/kernel/qwindow.h
+++ b/src/gui/kernel/qwindow.h
@@ -71,7 +71,7 @@ class QShowEvent;
class QHideEvent;
class QKeyEvent;
class QMouseEvent;
-#ifndef QT_NO_WHEELEVENT
+#if QT_CONFIG(wheelevent)
class QWheelEvent;
#endif
class QTouchEvent;
@@ -344,7 +344,7 @@ protected:
virtual void mouseReleaseEvent(QMouseEvent *);
virtual void mouseDoubleClickEvent(QMouseEvent *);
virtual void mouseMoveEvent(QMouseEvent *);
-#ifndef QT_NO_WHEELEVENT
+#if QT_CONFIG(wheelevent)
virtual void wheelEvent(QWheelEvent *);
#endif
virtual void touchEvent(QTouchEvent *);