diff options
author | Friedemann Kleint <Friedemann.Kleint@nokia.com> | 2011-11-28 14:33:54 +0100 |
---|---|---|
committer | Qt by Nokia <qt-info@nokia.com> | 2011-11-28 16:57:58 +0100 |
commit | b8d330904b279de57d70caef70ab2d2a6770f0cc (patch) | |
tree | a9edf91fa9b80142bdcdf2912b2701704bf7ca6c /src/plugins/platforms/windows/qwindowsscreen.cpp | |
parent | f6c107d799d14bbdb2cb71b8446483541bb0adb5 (diff) |
QtGui: Bring back HBITMAP/HICON conversion functions.
- Move the conversion functions from the Lighthouse plugin
to QtGui as qt_pixmap/From/To/HBITMAP/HICON().
- Re-enable them in Widgets (QFileIconProvider, QWindowsStyle).
- Use them in QtPrintSupport.
Change-Id: I1436bc604160d94c78ef270ad2b31bf3b20b5c90
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
Diffstat (limited to 'src/plugins/platforms/windows/qwindowsscreen.cpp')
-rw-r--r-- | src/plugins/platforms/windows/qwindowsscreen.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/plugins/platforms/windows/qwindowsscreen.cpp b/src/plugins/platforms/windows/qwindowsscreen.cpp index 96f3917cf4..08696a646b 100644 --- a/src/plugins/platforms/windows/qwindowsscreen.cpp +++ b/src/plugins/platforms/windows/qwindowsscreen.cpp @@ -42,7 +42,6 @@ #include "qwindowsscreen.h" #include "qwindowscontext.h" #include "qwindowswindow.h" -#include "pixmaputils.h" #include "qwindowscursor.h" #include "qtwindows_additional.h" @@ -150,6 +149,8 @@ QList<QPlatformScreen *> QWindowsScreen::screens() QPixmap QWindowsScreen::grabWindow(WId window, int x, int y, int width, int height) const { + Q_GUI_EXPORT QPixmap qt_pixmapFromWinHBITMAP(HBITMAP bitmap, int hbitmapFormat = 0); + if (QWindowsContext::verboseIntegration) qDebug() << __FUNCTION__ << window << x << y << width << height; RECT r; @@ -174,7 +175,7 @@ QPixmap QWindowsScreen::grabWindow(WId window, int x, int y, int width, int heig SelectObject(bitmap_dc, null_bitmap); DeleteDC(bitmap_dc); - const QPixmap pixmap = qPixmapFromWinHBITMAP(bitmap, HBitmapNoAlpha); + const QPixmap pixmap = qt_pixmapFromWinHBITMAP(bitmap); DeleteObject(bitmap); ReleaseDC(0, display_dc); |