From 8f4b6a89731b4d341d3bf33d1e2b8fc08d4bd08e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Fl=C3=B6ser?= Date: Wed, 18 Oct 2017 22:05:22 +0200 Subject: [PATCH] Drop the explicit fallback to XRender Summary: With the new try of all compositor types supported there is an automatic fallback from OpenGL to XRender/QPainter in case OpenGL setup failed. So there is no need to invoke a method to do just that. Reviewers: #kwin, #plasma Subscribers: plasma-devel Tags: #plasma Differential Revision: https://phabricator.kde.org/D8364 --- composite.cpp | 11 ----------- composite.h | 1 - plugins/scenes/opengl/scene_opengl.cpp | 1 - 3 files changed, 13 deletions(-) diff --git a/composite.cpp b/composite.cpp index aac7966cd..4d71bb5a5 100644 --- a/composite.cpp +++ b/composite.cpp @@ -477,17 +477,6 @@ void Compositor::deleteUnusedSupportProperties() } } -// OpenGL self-check failed, fallback to XRender -void Compositor::fallbackToXRenderCompositing() -{ - finish(); - KConfigGroup config(kwinApp()->config(), "Compositing"); - config.writeEntry("Backend", "XRender"); - config.sync(); - options->setCompositingMode(XRenderCompositing); - setup(); -} - void Compositor::slotConfigChanged() { if (!m_suspended) { diff --git a/composite.h b/composite.h index 9f6590cfc..463da5fc7 100644 --- a/composite.h +++ b/composite.h @@ -193,7 +193,6 @@ private Q_SLOTS: * That is the Compositor will be stopped and started again. **/ void restart(); - void fallbackToXRenderCompositing(); void performCompositing(); void slotConfigChanged(); void releaseCompositorSelection(); diff --git a/plugins/scenes/opengl/scene_opengl.cpp b/plugins/scenes/opengl/scene_opengl.cpp index 59a385de8..35885df9a 100644 --- a/plugins/scenes/opengl/scene_opengl.cpp +++ b/plugins/scenes/opengl/scene_opengl.cpp @@ -510,7 +510,6 @@ SceneOpenGL *SceneOpenGL::createScene(QObject *parent) qCCritical(KWIN_OPENGL) << "OpenGL driver recommends XRender based compositing. Falling back to XRender."; qCCritical(KWIN_OPENGL) << "To overwrite the detection use the environment variable KWIN_COMPOSE"; qCCritical(KWIN_OPENGL) << "For more information see http://community.kde.org/KWin/Environment_Variables#KWIN_COMPOSE"; - QTimer::singleShot(0, Compositor::self(), SLOT(fallbackToXRenderCompositing())); } delete backend; }