diff options
author | David Faure <faure+bluesystems@kde.org> | 2012-12-04 16:57:17 +0100 |
---|---|---|
committer | The Qt Project <gerrit-noreply@qt-project.org> | 2012-12-14 08:56:02 +0100 |
commit | 60bd2156f81b154a47c95989b0266944fd2f2859 (patch) | |
tree | fa1589263b8d2a5b6184634b453bcc9262b5a8f7 /src/plugins/platforms/xcb/qxcbnativeinterface.h | |
parent | 92bd9aecfb69ebe525ba88dc78ce85e3ca7ed9c2 (diff) |
XCB: add support for getting and setting appTime and appUserTime.
The QX11Info class needs this.
This required adding the missing nativeResourceFunctionForScreen
in QPlatformNativeInterface.
Change-Id: I2c6e91c7f122f3ecdf769a177deafd2aa3896e2f
Reviewed-by: Richard J. Moore <rich@kde.org>
Reviewed-by: Alberto Mardegan <mardy@users.sourceforge.net>
Reviewed-by: Samuel Rødal <samuel.rodal@digia.com>
Diffstat (limited to 'src/plugins/platforms/xcb/qxcbnativeinterface.h')
-rw-r--r-- | src/plugins/platforms/xcb/qxcbnativeinterface.h | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/src/plugins/platforms/xcb/qxcbnativeinterface.h b/src/plugins/platforms/xcb/qxcbnativeinterface.h index a7e0a207cb..e2e03fce8f 100644 --- a/src/plugins/platforms/xcb/qxcbnativeinterface.h +++ b/src/plugins/platforms/xcb/qxcbnativeinterface.h @@ -43,11 +43,13 @@ #define QXCBNATIVEINTERFACE_H #include <qpa/qplatformnativeinterface.h> +#include <xcb/xcb.h> QT_BEGIN_NAMESPACE class QWidget; class QXcbScreen; +class QXcbConnection; class QXcbNativeInterface : public QPlatformNativeInterface { @@ -59,7 +61,9 @@ public: Screen, GraphicsDevice, EglContext, - GLXContext + GLXContext, + AppTime, + AppUserTime }; QXcbNativeInterface(); @@ -69,6 +73,7 @@ public: void *nativeResourceForWindow(const QByteArray &resourceString, QWindow *window); NativeResourceForContextFunction nativeResourceFunctionForContext(const QByteArray &resource); + NativeResourceForScreenFunction nativeResourceFunctionForScreen(const QByteArray &resource) Q_DECL_OVERRIDE; inline const QByteArray &genericEventFilterType() const { return m_genericEventFilterType; } @@ -77,6 +82,10 @@ public: void *connectionForWindow(QWindow *window); void *screenForWindow(QWindow *window); void *graphicsDeviceForWindow(QWindow *window); + void *appTime(const QXcbScreen *screen); + void *appUserTime(const QXcbScreen *screen); + static void setAppTime(QScreen *screen, xcb_timestamp_t time); + static void setAppUserTime(QScreen *screen, xcb_timestamp_t time); static void *eglContextForContext(QOpenGLContext *context); static void *glxContextForContext(QOpenGLContext *context); |