diff options
author | Qt Continuous Integration System <qt-info@nokia.com> | 2011-01-07 07:51:45 (GMT) |
---|---|---|
committer | Qt Continuous Integration System <qt-info@nokia.com> | 2011-01-07 07:51:45 (GMT) |
commit | b71a43deb870352aa647c395e6bb02d9f20f50e5 (patch) | |
tree | b7283e42837539af8f979cbba14da85e729468b2 | |
parent | 9cc21c043238dc7576a465c9d236e8968fd8c549 (diff) | |
parent | 84658ec4e650b12dcea6f886b530e66a195465cf (diff) | |
download | Qt-b71a43deb870352aa647c395e6bb02d9f20f50e5.zip Qt-b71a43deb870352aa647c395e6bb02d9f20f50e5.tar.gz Qt-b71a43deb870352aa647c395e6bb02d9f20f50e5.tar.bz2 |
Merge branch '4.7' of scm.dev.nokia.troll.no:qt/oslo-staging-2 into 4.7-integration
* '4.7' of scm.dev.nokia.troll.no:qt/oslo-staging-2:
Fixed bug and performance problem in windowsstyle.
Restored old flushing behavior in -graphicssystem opengl on desktop.
-rw-r--r-- | src/gui/styles/qwindowsstyle.cpp | 4 | ||||
-rw-r--r-- | src/opengl/qwindowsurface_gl.cpp | 7 |
2 files changed, 6 insertions, 5 deletions
diff --git a/src/gui/styles/qwindowsstyle.cpp b/src/gui/styles/qwindowsstyle.cpp index 32a6d8d..4144b80 100644 --- a/src/gui/styles/qwindowsstyle.cpp +++ b/src/gui/styles/qwindowsstyle.cpp @@ -1395,8 +1395,8 @@ void QWindowsStyle::drawPrimitive(PrimitiveElement pe, const QStyleOption *opt, if (!QPixmapCache::find(pixmapName, pixmap)) { int border = size/5; int sqsize = 2*(size/2); - QImage image(sqsize, sqsize, QImage::Format_ARGB32); - image.fill(Qt::transparent); + QImage image(sqsize, sqsize, QImage::Format_ARGB32_Premultiplied); + image.fill(0); QPainter imagePainter(&image); QPolygon a; diff --git a/src/opengl/qwindowsurface_gl.cpp b/src/opengl/qwindowsurface_gl.cpp index b8716ce..7243f02 100644 --- a/src/opengl/qwindowsurface_gl.cpp +++ b/src/opengl/qwindowsurface_gl.cpp @@ -520,9 +520,10 @@ void QGLWindowSurface::flush(QWidget *widget, const QRegion &rgn, const QPoint & // did_paint is set to true in ::beginPaint. ::beginPaint means that we // at least cleared the background (= painted something). In EGL API it's a - // mistakte to call swapBuffers if nothing was painted. This check protects - // the flush func from being executed if it's for nothing. - if (!d_ptr->did_paint) + // mistake to call swapBuffers if nothing was painted unless + // EGL_BUFFER_PRESERVED is set. This check protects the flush func from + // being executed if it's for nothing. + if (!hasPartialUpdateSupport() && !d_ptr->did_paint) return; QWidget *parent = widget->internalWinId() ? widget : widget->nativeParentWidget(); |