summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorRaphael Kubo da Costa <rakuco@FreeBSD.org>2013-04-07 16:53:25 (GMT)
committerThe Qt Project <gerrit-noreply@qt-project.org>2013-04-23 12:42:38 (GMT)
commit4b69ada361117757a1d9dfd6a9cd444fcb433edc (patch)
tree62270037d3e186bd16f2989135ceeb8b2453b291 /src
parente36e83b5e65a703058ec5a4e4418fe6a49d73e2c (diff)
downloadQt-4b69ada361117757a1d9dfd6a9cd444fcb433edc.zip
Qt-4b69ada361117757a1d9dfd6a9cd444fcb433edc.tar.gz
Qt-4b69ada361117757a1d9dfd6a9cd444fcb433edc.tar.bz2
Fix C++11 narrowing error.
src/opengl/qgl_x11.cpp:1805:21: error: non-constant-expression cannot be narrowed from type 'unsigned int' to 'int' in initializer list [-Wc++11-narrowing] 0x20D4, options & QGLContext::CanFlipNativePixmapBindOption ? 0xFFFFFFFF : 0, Simply add an explicit cast to the expression to make it build with libc++. No cherry-pick, this file does not exist in qt5. Change-Id: Ic2fc636fc21a87dae848c062acb048e4a623a1f2 Reviewed-by: Samuel Rødal <samuel.rodal@digia.com>
Diffstat (limited to 'src')
-rw-r--r--src/opengl/qgl_x11.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/opengl/qgl_x11.cpp b/src/opengl/qgl_x11.cpp
index bce1935..233d5a2 100644
--- a/src/opengl/qgl_x11.cpp
+++ b/src/opengl/qgl_x11.cpp
@@ -1802,7 +1802,7 @@ QGLTexture *QGLContextPrivate::bindTextureFromNativePixmap(QPixmap *pixmap, cons
GLX_DRAWABLE_TYPE, GLX_PIXMAP_BIT,
GLX_BIND_TO_TEXTURE_TARGETS_EXT, GLX_TEXTURE_2D_BIT_EXT,
// QGLContext::bindTexture() can't return an inverted texture, but QPainter::drawPixmap() can:
- GLX_Y_INVERTED_EXT, options & QGLContext::CanFlipNativePixmapBindOption ? GLX_DONT_CARE : False,
+ GLX_Y_INVERTED_EXT, int(options & QGLContext::CanFlipNativePixmapBindOption ? GLX_DONT_CARE : False),
XNone
};
configList = glXChooseFBConfig(x11Info.display(), x11Info.screen(), configAttribs, &configCount);