diff options
author | Friedemann Kleint <Friedemann.Kleint@digia.com> | 2013-11-18 16:15:17 (GMT) |
---|---|---|
committer | The Qt Project <gerrit-noreply@qt-project.org> | 2013-11-18 17:31:06 (GMT) |
commit | bc03cbe1cb00dd19406d5999950f4abb28c8de0e (patch) | |
tree | 4a71a0386f6be32792b89e5455a145f57f24f221 /src/gui | |
parent | f04db51dbb10853205725a6af6f1252c372bb16a (diff) | |
download | Qt-bc03cbe1cb00dd19406d5999950f4abb28c8de0e.zip Qt-bc03cbe1cb00dd19406d5999950f4abb28c8de0e.tar.gz Qt-bc03cbe1cb00dd19406d5999950f4abb28c8de0e.tar.bz2 |
Fix MinGW-warnings about narrowing/invalid conversions.
Change-Id: I9b49dd6d12a5e59c6f2674ab3c82a8a7ec583775
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
Diffstat (limited to 'src/gui')
-rw-r--r-- | src/gui/kernel/qwidget_win.cpp | 2 | ||||
-rw-r--r-- | src/gui/painting/qwindowsurface_raster.cpp | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/src/gui/kernel/qwidget_win.cpp b/src/gui/kernel/qwidget_win.cpp index c90cd9c..16265e9 100644 --- a/src/gui/kernel/qwidget_win.cpp +++ b/src/gui/kernel/qwidget_win.cpp @@ -1922,7 +1922,7 @@ void QWidgetPrivate::setWindowOpacity_sys(qreal level) if (!isOpaque && ptrUpdateLayeredWindow && (data.window_flags & Qt::FramelessWindowHint)) { if (GetWindowLong(q->internalWinId(), GWL_EXSTYLE) & Q_WS_EX_LAYERED) { - BLENDFUNCTION blend = {AC_SRC_OVER, 0, (int)(255.0 * level), AC_SRC_ALPHA}; + BLENDFUNCTION blend = {AC_SRC_OVER, 0, (BYTE)(255.0 * level), AC_SRC_ALPHA}; ptrUpdateLayeredWindow(q->internalWinId(), NULL, NULL, NULL, NULL, NULL, 0, &blend, Q_ULW_ALPHA); } return; diff --git a/src/gui/painting/qwindowsurface_raster.cpp b/src/gui/painting/qwindowsurface_raster.cpp index 3493dd8..2b8af81 100644 --- a/src/gui/painting/qwindowsurface_raster.cpp +++ b/src/gui/painting/qwindowsurface_raster.cpp @@ -186,7 +186,7 @@ void QRasterWindowSurface::flush(QWidget *widget, const QRegion &rgn, const QPoi SIZE size = {r.width(), r.height()}; POINT ptDst = {r.x(), r.y()}; POINT ptSrc = {0, 0}; - BLENDFUNCTION blend = {AC_SRC_OVER, 0, (int)(255.0 * window()->windowOpacity()), Q_AC_SRC_ALPHA}; + BLENDFUNCTION blend = {AC_SRC_OVER, 0, (BYTE)(255.0 * window()->windowOpacity()), Q_AC_SRC_ALPHA}; RECT dirty = {dirtyRect.x(), dirtyRect.y(), dirtyRect.x() + dirtyRect.width(), dirtyRect.y() + dirtyRect.height()}; Q_UPDATELAYEREDWINDOWINFO info = {sizeof(info), NULL, &ptDst, &size, d->image->hdc, &ptSrc, 0, &blend, Q_ULW_ALPHA, &dirty}; |