Changeset View
Changeset View
Standalone View
Standalone View
shell/desktopview.cpp
Show First 20 Lines • Show All 51 Lines • ▼ Show 20 Line(s) | 42 | { | |||
---|---|---|---|---|---|
52 | rootContext()->setContextProperty(QStringLiteral("desktop"), this); | 52 | rootContext()->setContextProperty(QStringLiteral("desktop"), this); | ||
53 | setSource(corona->kPackage().fileUrl("views", QStringLiteral("Desktop.qml"))); | 53 | setSource(corona->kPackage().fileUrl("views", QStringLiteral("Desktop.qml"))); | ||
54 | 54 | | |||
55 | connect(this, &QWindow::screenChanged, this, &DesktopView::adaptToScreen); | 55 | connect(this, &QWindow::screenChanged, this, &DesktopView::adaptToScreen); | ||
56 | 56 | | |||
57 | QObject::connect(corona, &Plasma::Corona::kPackageChanged, | 57 | QObject::connect(corona, &Plasma::Corona::kPackageChanged, | ||
58 | this, &DesktopView::coronaPackageChanged); | 58 | this, &DesktopView::coronaPackageChanged); | ||
59 | 59 | | |||
60 | if (QQuickWindow::sceneGraphBackend() != QLatin1String("software")) { | 60 | if (rendererInterface()->graphicsApi() != QSGRendererInterface::Software) { | ||
61 | connect(this, &DesktopView::sceneGraphInitialized, this, | 61 | connect(this, &DesktopView::sceneGraphInitialized, this, | ||
62 | [this, corona]() { | 62 | [this, corona]() { | ||
63 | // check whether the GL Context supports OpenGL | 63 | // check whether the GL Context supports OpenGL | ||
graesslin: This looks like too much debug or like a need of qcdebug | |||||
64 | // Note: hasOpenGLShaderPrograms is broken, see QTBUG--39730 | 64 | // Note: hasOpenGLShaderPrograms is broken, see QTBUG--39730 | ||
65 | if (!QOpenGLShaderProgram::hasOpenGLShaderPrograms(openglContext())) { | 65 | if (!QOpenGLShaderProgram::hasOpenGLShaderPrograms(openglContext())) { | ||
66 | qWarning() << "GLSL not available, Plasma won't be functional"; | 66 | qWarning() << "GLSL not available, Plasma won't be functional"; | ||
67 | QMetaObject::invokeMethod(corona, "showOpenGLNotCompatibleWarning", Qt::QueuedConnection); | 67 | QMetaObject::invokeMethod(corona, "glInitialisationFailed", Qt::QueuedConnection); | ||
68 | } | 68 | } | ||
69 | }, Qt::DirectConnection); | 69 | }, Qt::DirectConnection); | ||
70 | } | 70 | } | ||
71 | } | 71 | } | ||
72 | 72 | | |||
73 | DesktopView::~DesktopView() | 73 | DesktopView::~DesktopView() | ||
74 | { | 74 | { | ||
75 | } | 75 | } | ||
▲ Show 20 Lines • Show All 245 Lines • Show Last 20 Lines |
This looks like too much debug or like a need of qcdebug