diff options
author | Tom Cooksey <thomas.cooksey@nokia.com> | 2010-04-08 10:29:07 (GMT) |
---|---|---|
committer | Tom Cooksey <thomas.cooksey@nokia.com> | 2010-04-08 10:29:07 (GMT) |
commit | 7b3f1a992e25739a8a28cf0470ba58fd31a46e7b (patch) | |
tree | 39985008d6fb1efededc7926e273733c2750aaca | |
parent | 0e342cd341f8d71b41de89340cbbf455694becc9 (diff) | |
download | Qt-7b3f1a992e25739a8a28cf0470ba58fd31a46e7b.zip Qt-7b3f1a992e25739a8a28cf0470ba58fd31a46e7b.tar.gz Qt-7b3f1a992e25739a8a28cf0470ba58fd31a46e7b.tar.bz2 |
Rename qglplatformintegration_lite.h & add QGLWidget surface
-rw-r--r-- | src/gui/kernel/qplatformintegration_lite.cpp | 5 | ||||
-rw-r--r-- | src/gui/kernel/qplatformintegration_lite.h | 5 | ||||
-rw-r--r-- | src/opengl/opengl.pro | 2 | ||||
-rw-r--r-- | src/opengl/qgl_lite.cpp | 10 | ||||
-rw-r--r-- | src/opengl/qgl_p.h | 2 | ||||
-rw-r--r-- | src/opengl/qglplatformintegration_lite.h (renamed from src/opengl/qplatformglcontext_lite.h) | 11 | ||||
-rw-r--r-- | src/plugins/platforms/testlite/qglxglcontext.h | 2 |
7 files changed, 32 insertions, 5 deletions
diff --git a/src/gui/kernel/qplatformintegration_lite.cpp b/src/gui/kernel/qplatformintegration_lite.cpp index 71beded..3fa874c 100644 --- a/src/gui/kernel/qplatformintegration_lite.cpp +++ b/src/gui/kernel/qplatformintegration_lite.cpp @@ -66,6 +66,11 @@ QPlatformGLContext * QPlatformIntegration::createGLContext() { return 0; } + +QPlatformGLWidgetSurface * QPlatformIntegration::createGLWidgetSurface(QGLWidget*) +{ + return 0; +} #endif QT_END_NAMESPACE diff --git a/src/gui/kernel/qplatformintegration_lite.h b/src/gui/kernel/qplatformintegration_lite.h index 9125bd1..2018c70 100644 --- a/src/gui/kernel/qplatformintegration_lite.h +++ b/src/gui/kernel/qplatformintegration_lite.h @@ -53,6 +53,8 @@ QT_MODULE(Gui) #ifndef QT_NO_OPENGL class QPlatformGLContext; +class QPlatformGLWidgetSurface; +class QGLWidget; #endif class Q_GUI_EXPORT QPlatformIntegration @@ -72,7 +74,8 @@ public: // OpenGL Integration functions #ifndef QT_NO_OPENGL virtual bool hasOpenGL() const; - virtual QPlatformGLContext * createGLContext(); + virtual QPlatformGLContext * createGLContext(); + virtual QPlatformGLWidgetSurface * createGLWidgetSurface(QGLWidget*); #endif }; diff --git a/src/opengl/opengl.pro b/src/opengl/opengl.pro index cebb677..42608e3 100644 --- a/src/opengl/opengl.pro +++ b/src/opengl/opengl.pro @@ -78,7 +78,7 @@ SOURCES += qgl.cpp \ embedded_lite { SOURCES += qgl_lite.cpp - HEADERS += qplatformglcontext_lite.h + HEADERS += qglplatformintegration_lite.h # If we have EGL, use the EGL implementation of QGLPixelBuffer, otherwise we just provide # a stubbed out one. PBuffers aren't too interesting anyway. diff --git a/src/opengl/qgl_lite.cpp b/src/opengl/qgl_lite.cpp index db1077d..a46593e 100644 --- a/src/opengl/qgl_lite.cpp +++ b/src/opengl/qgl_lite.cpp @@ -47,7 +47,7 @@ #include "qgl.h" #include "qgl_p.h" -#include "qplatformglcontext_lite.h" +#include "qglplatformintegration_lite.h" QT_BEGIN_NAMESPACE @@ -60,6 +60,14 @@ QPlatformGLContext::~QPlatformGLContext() { } +QPlatformGLWidgetSurface::QPlatformGLWidgetSurface(QGLWidget*) +{ +} + +QPlatformGLWidgetSurface::~QPlatformGLWidgetSurface() +{ +} + bool QGLFormat::hasOpenGL() { diff --git a/src/opengl/qgl_p.h b/src/opengl/qgl_p.h index f53b3e2..6405a54 100644 --- a/src/opengl/qgl_p.h +++ b/src/opengl/qgl_p.h @@ -69,7 +69,7 @@ #endif #if defined(Q_WS_LITE) -#include <qplatformglcontext_lite.h> +#include <qglplatformintegration_lite.h> #endif QT_BEGIN_NAMESPACE diff --git a/src/opengl/qplatformglcontext_lite.h b/src/opengl/qglplatformintegration_lite.h index 10c05f6..d5bae45 100644 --- a/src/opengl/qplatformglcontext_lite.h +++ b/src/opengl/qglplatformintegration_lite.h @@ -63,6 +63,17 @@ public: }; +// QGLPlatformWidgetSurface does _not_ inherit from QWindowSurface +// - The backing store may be totally unaware of it's existance. +class QPlatformGLWidgetSurface +{ +public: + QPlatformGLWidgetSurface(QGLWidget*); + virtual ~QPlatformGLWidgetSurface(); + + virtual void setGeometry(const QRect&) = 0; +}; + QT_END_NAMESPACE diff --git a/src/plugins/platforms/testlite/qglxglcontext.h b/src/plugins/platforms/testlite/qglxglcontext.h index 54e5c2f..ff8fe85 100644 --- a/src/plugins/platforms/testlite/qglxglcontext.h +++ b/src/plugins/platforms/testlite/qglxglcontext.h @@ -42,7 +42,7 @@ #ifndef Q_GLX_CONTEXT_H #define Q_GLX_CONTEXT_H -#include <QtOpenGL/qplatformglcontext_lite.h> +#include <QtOpenGL/qglplatformintegration_lite.h> #include "x11util.h" #include <GL/glx.h> |