summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKim Motoyoshi Kalland <kim.kalland@nokia.com>2010-06-18 15:09:12 +0200
committerJason McDonald <jason.mcdonald@nokia.com>2010-06-30 11:06:24 +1000
commit0fef3b8463a3d3b9bb0e4e08b964794eb40bd55d (patch)
tree1056c87dffa52d5cced964c68d9da76fdc47e3f0
parentf14b9b1bbb023ba8f28839bab456e09040449851 (diff)
Fixed device context leak in QGLWidget on Windows.
Commit 392123ef5432643d1047d1e1dd71512ec39d382d introduced the leak. Task-number: QTBUG-11432 Reviewed-by: Trond (cherry picked from commit 38adb59a9e80a23d37ff0820ef62ebd45ab1e4ae)
-rw-r--r--src/gui/kernel/qapplication_win.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/gui/kernel/qapplication_win.cpp b/src/gui/kernel/qapplication_win.cpp
index 09535fa0e6..cf28893f35 100644
--- a/src/gui/kernel/qapplication_win.cpp
+++ b/src/gui/kernel/qapplication_win.cpp
@@ -957,6 +957,9 @@ const QString qt_reg_winclass(QWidget *w) // register window class
if (qt_widget_private(w)->isGLWidget) {
cname = QLatin1String("QGLWidget");
style = CS_DBLCLKS;
+#ifndef Q_WS_WINCE
+ style |= CS_OWNDC;
+#endif
icon = true;
} else if (flags & Qt::MSWindowsOwnDC) {
cname = QLatin1String("QWidgetOwnDC");