diff options
author | Samuel Rødal <samuel.rodal@nokia.com> | 2011-06-21 13:39:26 +0200 |
---|---|---|
committer | Samuel Rødal <samuel.rodal@nokia.com> | 2011-06-21 14:02:22 +0200 |
commit | 176f30b13739b352cbe453cba7796d9a9c808bcd (patch) | |
tree | 8fa60b6ae4ef06455652863a0406bc5e86a22303 /src/plugins/platforms/wayland/qwaylandintegration.cpp | |
parent | 272daebaa07b21e372ad4274fafb51ce0be92396 (diff) |
OpenGL API refactor.
Rename QGuiGLFormat to QSurfaceFormat, and make QWindow sub-class of
QSurface and QPlatformWindow sub-class of QPlatformSurface, instead of
having QPlatformGLSurface accessor in QWindow.
Diffstat (limited to 'src/plugins/platforms/wayland/qwaylandintegration.cpp')
-rw-r--r-- | src/plugins/platforms/wayland/qwaylandintegration.cpp | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/src/plugins/platforms/wayland/qwaylandintegration.cpp b/src/plugins/platforms/wayland/qwaylandintegration.cpp index 9cd79e2978..dc59d37f40 100644 --- a/src/plugins/platforms/wayland/qwaylandintegration.cpp +++ b/src/plugins/platforms/wayland/qwaylandintegration.cpp @@ -51,7 +51,7 @@ #include <QtGui/QWindowSystemInterface> #include <QtGui/QPlatformCursor> -#include <QtGui/QGuiGLFormat> +#include <QtGui/QSurfaceFormat> #include <QtGui/private/qpixmap_raster_p.h> @@ -100,18 +100,19 @@ QPixmapData *QWaylandIntegration::createPixmapData(QPixmapData::PixelType type) QPlatformWindow *QWaylandIntegration::createPlatformWindow(QWindow *window) const { #ifdef QT_WAYLAND_GL_SUPPORT - if (window->surfaceType() == QWindow::OpenGLSurface) - return mDisplay->eglIntegration()->createEglWindow(window); -#endif - + return mDisplay->eglIntegration()->createEglWindow(window); +#else return new QWaylandShmWindow(window); +#endif } -QPlatformGLContext *QWaylandIntegration::createPlatformGLContext(const QGuiGLFormat &glFormat, QPlatformGLContext *share) const +QPlatformGLContext *QWaylandIntegration::createPlatformGLContext(const QSurfaceFormat &glFormat, QPlatformGLContext *share) const { #ifdef QT_WAYLAND_GL_SUPPORT return mDisplay->eglIntegration()->createPlatformGLContext(glFormat, share); #else + Q_UNUSED(glFormat); + Q_UNUSED(share); return 0; #endif } |