From 0f49ebb4c21007f62055c3390fe925a7d4d6b34c Mon Sep 17 00:00:00 2001 From: Thomas McGuire Date: Wed, 11 Jul 2012 16:41:32 +0200 Subject: QNX: Fix flushing the backing store to non-owner windows Multiple windows can share the same backing store, which we did not take into account. Don't ignore the window parameter in flush() to fix that. Change-Id: I4f98bba34d4da9134163e478cb78cab4ca0358d2 Reviewed-by: Rafael Roquetto Reviewed-by: Marc Mutz Reviewed-by: Kevin Krammer Reviewed-by: Giuseppe D'Angelo --- src/plugins/platforms/qnx/qqnxwindow.cpp | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'src/plugins/platforms/qnx/qqnxwindow.cpp') diff --git a/src/plugins/platforms/qnx/qqnxwindow.cpp b/src/plugins/platforms/qnx/qqnxwindow.cpp index 572dff7289..95604a5e22 100644 --- a/src/plugins/platforms/qnx/qqnxwindow.cpp +++ b/src/plugins/platforms/qnx/qqnxwindow.cpp @@ -639,6 +639,19 @@ QQnxWindow *QQnxWindow::findWindow(screen_window_t windowHandle) return 0; } +void QQnxWindow::blitFrom(QQnxWindow *sourceWindow, const QPoint &sourceOffset, const QRegion &targetRegion) +{ + if (!sourceWindow || sourceWindow->m_previousBufferIndex == -1 || targetRegion.isEmpty()) + return; + + qWindowDebug() << Q_FUNC_INFO << window() << sourceWindow->window() << sourceOffset << targetRegion; + + QQnxBuffer &sourceBuffer = sourceWindow->m_buffers[sourceWindow->m_previousBufferIndex]; + QQnxBuffer &targetBuffer = renderBuffer(); + + blitHelper(sourceBuffer, targetBuffer, sourceOffset, QPoint(0, 0), targetRegion, true); +} + void QQnxWindow::updateZorder(int &topZorder) { errno = 0; -- cgit v1.2.3