Since QOpenGLContext is now a QObject, it needs to be moved to, or
created in, the thread where it's going to be used.
Change-Id: I7ed12b25e75c84bb12be8c7102e46e9a242fc2df
Reviewed-on: http://codereview.qt.nokia.com/3858
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com>
if (!d->platformGLContext)
return false;
+ if (thread() != QThread::currentThread())
+ qFatal("Cannot make QOpenGLContext current in a different thread");
+
if (!surface) {
doneCurrent();
return true;