summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorMichael Dominic K <mdk@codethink.co.uk>2010-07-21 09:17:33 (GMT)
committerToby Tomkins <toby.tomkins@nokia.com>2010-07-27 00:10:46 (GMT)
commit00df0354e08078b21aaca369ab5f0efa19b27fe2 (patch)
tree8fe6ce151ccf1a6f3b8255ca9fa6e8dba28e452d /src
parenta38bfb1807cb36240e0102935b23fe1ac474d035 (diff)
downloadQt-00df0354e08078b21aaca369ab5f0efa19b27fe2.zip
Qt-00df0354e08078b21aaca369ab5f0efa19b27fe2.tar.gz
Qt-00df0354e08078b21aaca369ab5f0efa19b27fe2.tar.bz2
Do check after all if we have partialUpdateSupport.
Task-number: QTBUG-12266 Merge-request: 752 Reviewed-by: Trond (cherry picked from commit d6203cfeb0e096575c1fc0254dddc07a3d65d24c)
Diffstat (limited to 'src')
-rw-r--r--src/opengl/qwindowsurface_gl.cpp7
1 files changed, 3 insertions, 4 deletions
diff --git a/src/opengl/qwindowsurface_gl.cpp b/src/opengl/qwindowsurface_gl.cpp
index e9da452..6b82ed3 100644
--- a/src/opengl/qwindowsurface_gl.cpp
+++ b/src/opengl/qwindowsurface_gl.cpp
@@ -494,10 +494,9 @@ void QGLWindowSurface::flush(QWidget *widget, const QRegion &rgn, const QPoint &
}
}
#endif
- if (d_ptr->paintedRegion.boundingRect() != geometry()) {
- // Emits warning if not supported. Should never happen unless
- // setPartialUpdateSupport(true) has been called.
- context()->d_func()->swapRegion(&d_ptr->paintedRegion);
+ if (d_ptr->paintedRegion.boundingRect() != geometry() &&
+ hasPartialUpdateSupport()) {
+ context()->d_func()->swapRegion(&d_ptr->paintedRegion);
} else
context()->swapBuffers();