diff options
author | Samuel Rødal <samuel.rodal@nokia.com> | 2011-04-26 15:20:11 (GMT) |
---|---|---|
committer | Samuel Rødal <samuel.rodal@nokia.com> | 2011-04-26 15:43:04 (GMT) |
commit | 1124f41253edd0e03704db72b0e1b6b4b518bd0f (patch) | |
tree | 6e05f491240950148f86466653a0e18128b2f9ae | |
parent | 224226727f07e8940e0d3131fe7587b11cc4a6ca (diff) | |
download | Qt-1124f41253edd0e03704db72b0e1b6b4b518bd0f.zip Qt-1124f41253edd0e03704db72b0e1b6b4b518bd0f.tar.gz Qt-1124f41253edd0e03704db72b0e1b6b4b518bd0f.tar.bz2 |
Removed warning from QPixmap::handle().
With the new fromX11Pixmap function there are valid use-cases where
checking the handle() is useful also with the raster graphicssystem.
Reviewed-by: Thiago Macieira
-rw-r--r-- | src/gui/image/qpixmap.cpp | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/src/gui/image/qpixmap.cpp b/src/gui/image/qpixmap.cpp index 34804e5..c34f6ac 100644 --- a/src/gui/image/qpixmap.cpp +++ b/src/gui/image/qpixmap.cpp @@ -1224,12 +1224,8 @@ Qt::HANDLE QPixmap::handle() const { #if defined(Q_WS_X11) const QPixmapData *pd = pixmapData(); - if (pd) { - if (pd->classId() == QPixmapData::X11Class) - return static_cast<const QX11PixmapData*>(pd)->handle(); - else - qWarning("QPixmap::handle(): Pixmap is not an X11 class pixmap"); - } + if (pd && pd->classId() == QPixmapData::X11Class) + return static_cast<const QX11PixmapData*>(pd)->handle(); #endif return 0; } |