From 6bd8c3742e111301481d3658a7c0a970bb10d66b Mon Sep 17 00:00:00 2001 From: Rafael Roquetto Date: Mon, 26 May 2014 18:26:45 -0300 Subject: QNX: Fix clearing transparent buffer Testing whether alphaBufferSize() != 0 does not work, because when no alpha channel is present, alphaBufferSize() can return '-1', which will cause non-transparent windows to be wrongly cleared and an artifact will appear. Change-Id: Id9e985f105c0bb302cc6f53960a5dbae2acdb921 Reviewed-by: Frank Osterfeld Reviewed-by: Wolfgang Bremer Reviewed-by: Sergio Ahumada --- src/plugins/platforms/qnx/qqnxrasterbackingstore.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/plugins/platforms/qnx/qqnxrasterbackingstore.cpp') diff --git a/src/plugins/platforms/qnx/qqnxrasterbackingstore.cpp b/src/plugins/platforms/qnx/qqnxrasterbackingstore.cpp index 3109388fb2..e0ecb5c798 100644 --- a/src/plugins/platforms/qnx/qqnxrasterbackingstore.cpp +++ b/src/plugins/platforms/qnx/qqnxrasterbackingstore.cpp @@ -170,7 +170,7 @@ void QQnxRasterBackingStore::beginPaint(const QRegion ®ion) platformWindow()->adjustBufferSize(); - if (window()->requestedFormat().alphaBufferSize() != 0) { + if (window()->requestedFormat().alphaBufferSize() > 0) { foreach (const QRect &r, region.rects()) { // Clear transparent regions const int bg[] = { -- cgit v1.2.3