From 870f19f44b1eb2b93c7151dd48b8d9cd471acae8 Mon Sep 17 00:00:00 2001 From: Friedemann Kleint Date: Fri, 27 Jan 2012 14:09:36 +0100 Subject: Add native event filters to Windows, forward to Widgets. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Use prototypically for qwizard_win.cpp. Change-Id: I075e81ae1bc3d62d9f27e51c73c800ffd71cbcd6 Reviewed-by: Samuel Rødal --- src/gui/kernel/qwindowsysteminterface_qpa.cpp | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) (limited to 'src/gui/kernel/qwindowsysteminterface_qpa.cpp') diff --git a/src/gui/kernel/qwindowsysteminterface_qpa.cpp b/src/gui/kernel/qwindowsysteminterface_qpa.cpp index 999e1a67d1..ae94b75076 100644 --- a/src/gui/kernel/qwindowsysteminterface_qpa.cpp +++ b/src/gui/kernel/qwindowsysteminterface_qpa.cpp @@ -60,6 +60,17 @@ QMutex QWindowSystemInterfacePrivate::queueMutex; extern QPointer qt_last_mouse_receiver; +/*! + \class QWindowSystemInterface + \since 5.0 + \internal + \preliminary + \ingroup qpa + \brief The QWindowSystemInterface provides an event queue for the QPA platform. + + The platform plugins call the various functions to notify about events. The events are queued + until sendWindowSystemEvents() is called by the event dispatcher. +*/ void QWindowSystemInterface::handleEnterEvent(QWindow *tlw) { @@ -379,4 +390,17 @@ Qt::DropAction QWindowSystemInterface::handleDrop(QWindow *w, QMimeData *dropDat return QGuiApplicationPrivate::processDrop(w, dropData, p); } +/*! + \fn static QWindowSystemInterface::handleNativeEvent(QWindow *window, const QByteArray &eventType, void *message, long *result) + \brief Passes a native event identified by \a eventType to the \a window. + + \note This function can only be called from the GUI thread. + \sa QPlatformNativeInterface::setEventFilter() +*/ + +bool QWindowSystemInterface::handleNativeEvent(QWindow *window, const QByteArray &eventType, void *message, long *result) +{ + return QGuiApplicationPrivate::processNativeEvent(window, eventType, message, result); +} + QT_END_NAMESPACE -- cgit v1.2.3