summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorOlivier Goffart <olivier.goffart@nokia.com>2011-02-21 09:57:50 (GMT)
committerOlivier Goffart <olivier.goffart@nokia.com>2011-02-21 10:19:51 (GMT)
commitb8fddce9e6f8dbd30e21cc2d8b20bb1bb0bccba8 (patch)
tree4fec2d85d24260463d766ad73931abbab5bbaa9d
parentfcb5db93099cbd7ed7c3a02650aad1d49e999d81 (diff)
downloadQt-b8fddce9e6f8dbd30e21cc2d8b20bb1bb0bccba8.zip
Qt-b8fddce9e6f8dbd30e21cc2d8b20bb1bb0bccba8.tar.gz
Qt-b8fddce9e6f8dbd30e21cc2d8b20bb1bb0bccba8.tar.bz2
Avoid warning when seting a window icon
QPixmap::handle(): Pixmap is not an X11 class pixmap The problem was that the QBitmap constructor would re-create a copy of the bitmap in a image (because we are using the raster graphicssystem) Reviewed-by: sroedal
-rw-r--r--src/gui/kernel/qwidget_x11.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/gui/kernel/qwidget_x11.cpp b/src/gui/kernel/qwidget_x11.cpp
index 1723f64..418ed7d 100644
--- a/src/gui/kernel/qwidget_x11.cpp
+++ b/src/gui/kernel/qwidget_x11.cpp
@@ -1522,7 +1522,7 @@ void QWidgetPrivate::setWindowIcon_sys(bool forceReset)
|| !QX11Info::appDefaultColormap(xinfo.screen())) {
// unknown DE or non-default visual/colormap, use 1bpp bitmap
if (!forceReset || !topData->iconPixmap)
- topData->iconPixmap = new QBitmap(qt_toX11Pixmap(icon.pixmap(QSize(64,64))));
+ topData->iconPixmap = new QPixmap(qt_toX11Pixmap(QBitmap(icon.pixmap(QSize(64,64)))));
pixmap_handle = topData->iconPixmap->handle();
} else {
// default depth, use a normal pixmap (even though this