summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorTom Cooksey <thomas.cooksey@nokia.com>2010-02-24 12:41:29 (GMT)
committerTom Cooksey <thomas.cooksey@nokia.com>2010-03-02 08:24:25 (GMT)
commitebdfa7270f67e4ce3b5034aa5144fdabeaecbbcd (patch)
treea53f4052caf613785a0145bdafafda74bc5ba2eb /src
parentdbc62b34b54ec3294f1cf8248630fbd1eaad9cbc (diff)
downloadQt-ebdfa7270f67e4ce3b5034aa5144fdabeaecbbcd.zip
Qt-ebdfa7270f67e4ce3b5034aa5144fdabeaecbbcd.tar.gz
Qt-ebdfa7270f67e4ce3b5034aa5144fdabeaecbbcd.tar.bz2
Use QEgl::display in QGLTemporaryContext so EGL is init'd only once
Reviewed-By: Trond Kjernåsen
Diffstat (limited to 'src')
-rw-r--r--src/opengl/qgl_x11egl.cpp7
1 files changed, 1 insertions, 6 deletions
diff --git a/src/opengl/qgl_x11egl.cpp b/src/opengl/qgl_x11egl.cpp
index 99ff5b8..ff58fba 100644
--- a/src/opengl/qgl_x11egl.cpp
+++ b/src/opengl/qgl_x11egl.cpp
@@ -76,12 +76,7 @@ QGLTemporaryContext::QGLTemporaryContext(bool, QWidget *)
d->surface = 0;
int screen = 0;
- d->display = eglGetDisplay(EGLNativeDisplayType(X11->display));
-
- if (!eglInitialize(d->display, NULL, NULL)) {
- qWarning("QGLTemporaryContext: Unable to initialize EGL display.");
- return;
- }
+ d->display = QEgl::display();
EGLConfig config;
int numConfigs = 0;