From 9631f6314cd90aab5594ee379ad2fabe7c8a4c95 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Samuel=20R=C3=B8dal?= Date: Wed, 4 May 2011 13:14:33 +0200 Subject: [PATCH] Fix compilation of QtOpenGL. --- src/opengl/gl2paintengineex/qpaintengineex_opengl2.cpp | 4 ++-- src/opengl/qpaintengine_opengl.cpp | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/opengl/gl2paintengineex/qpaintengineex_opengl2.cpp b/src/opengl/gl2paintengineex/qpaintengineex_opengl2.cpp index 673f614..a7c9411 100644 --- a/src/opengl/gl2paintengineex/qpaintengineex_opengl2.cpp +++ b/src/opengl/gl2paintengineex/qpaintengineex_opengl2.cpp @@ -2357,8 +2357,8 @@ void QGL2PaintEngineExPrivate::systemStateChanged() if (systemClip.isEmpty()) { useSystemClip = false; } else { - if (q->paintDevice()->devType() == QInternal::Widget && currentClipWidget) { - QWidgetPrivate *widgetPrivate = qt_widget_private(currentClipWidget->window()); + if (q->paintDevice()->devType() == QInternal::Widget && currentClipDevice) { + QWidgetPrivate *widgetPrivate = qt_widget_private(static_cast(currentClipDevice)->window()); useSystemClip = widgetPrivate->extra && widgetPrivate->extra->inRenderWithPainter; } else { useSystemClip = true; diff --git a/src/opengl/qpaintengine_opengl.cpp b/src/opengl/qpaintengine_opengl.cpp index 9da811a..dffda11 100644 --- a/src/opengl/qpaintengine_opengl.cpp +++ b/src/opengl/qpaintengine_opengl.cpp @@ -2358,8 +2358,8 @@ void QOpenGLPaintEngine::updateClipRegion(const QRegion &clipRegion, Qt::ClipOpe } else { #ifndef Q_WS_QWS // Only use the system clip if we're currently rendering a widget with a GL painter. - if (d->currentClipWidget) { - QWidgetPrivate *widgetPrivate = qt_widget_private(d->currentClipWidget->window()); + if (d->currentClipDevice) { + QWidgetPrivate *widgetPrivate = qt_widget_private(static_cast(d->currentClipDevice)->window()); d->use_system_clip = widgetPrivate->extra && widgetPrivate->extra->inRenderWithPainter; } #endif -- 2.7.4