Commit 734725ff authored by Robert Loehning's avatar Robert Loehning

Welcome: Check in initialize if OpenGl context can be created

Task-number: QTCREATORBUG-15040
Change-Id: I8c78ac0a3b979c4ec8e088cd1be3c6aeb04ff339
Reviewed-by: default avatarEike Ziller <eike.ziller@theqtcompany.com>
parent f229f0db
......@@ -51,6 +51,7 @@
#include <QMessageBox>
#include <QDir>
#include <QOpenGLContext>
#include <QQmlPropertyMap>
#ifdef USE_QUICK_WIDGET
......@@ -286,8 +287,13 @@ WelcomePlugin::WelcomePlugin()
{
}
bool WelcomePlugin::initialize(const QStringList & /* arguments */, QString * /* errorMessage */)
bool WelcomePlugin::initialize(const QStringList & /* arguments */, QString *errorMessage)
{
if (!QOpenGLContext().create()) {
*errorMessage = tr("Cannot create OpenGL context.");
return false;
}
m_welcomeMode = new WelcomeMode;
addAutoReleasedObject(m_welcomeMode);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment