summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorTimur Pocheptsov <timur.pocheptsov@qt.io>2017-10-25 14:24:16 +0200
committerTimur Pocheptsov <timur.pocheptsov@qt.io>2017-10-28 06:07:38 +0000
commit464b50b58d1ff5240a97b0c7fa88ce8c42ca0801 (patch)
treea098bf4e5987e4b279a76423b6acd80d286d2017 /src
parent44401d26af696232b9452ef83cacde90aa372e06 (diff)
Fix -no-opengl build
A follow-up patch for 8e70241dccaf5a9e5c79c8d6da5665b881c5914d: Make 'shareContext' conditionally included/compiled (protected by QT_CONFIG(opengl)). Change-Id: Ieaeea6b146b47fba7a77e2576ae0a33042280199 Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io> Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io> Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@qt.io>
Diffstat (limited to 'src')
-rw-r--r--src/widgets/kernel/qwidgetwindow.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/widgets/kernel/qwidgetwindow.cpp b/src/widgets/kernel/qwidgetwindow.cpp
index 319eccf223..d8d6eab7b1 100644
--- a/src/widgets/kernel/qwidgetwindow.cpp
+++ b/src/widgets/kernel/qwidgetwindow.cpp
@@ -96,7 +96,9 @@ public:
}
QRectF closestAcceptableGeometry(const QRectF &rect) const Q_DECL_OVERRIDE;
+#if QT_CONFIG(opengl)
QOpenGLContext *shareContext() const override;
+#endif
};
QRectF QWidgetWindowPrivate::closestAcceptableGeometry(const QRectF &rect) const
@@ -128,12 +130,14 @@ QRectF QWidgetWindowPrivate::closestAcceptableGeometry(const QRectF &rect) const
return result;
}
+#if QT_CONFIG(opengl)
QOpenGLContext *QWidgetWindowPrivate::shareContext() const
{
Q_Q(const QWidgetWindow);
const QWidgetPrivate *widgetPrivate = QWidgetPrivate::get(q->widget());
return widgetPrivate->shareContext();
}
+#endif // opengl
QWidgetWindow::QWidgetWindow(QWidget *widget)
: QWindow(*new QWidgetWindowPrivate(), 0)