diff options
author | Johan Klokkhammer Helsing <johan.helsing@qt.io> | 2018-05-08 16:31:16 +0200 |
---|---|---|
committer | Johan Helsing <johan.helsing@qt.io> | 2018-05-09 11:04:35 +0000 |
commit | f11c2993d2173d97ab74a36cac5603dff1c32997 (patch) | |
tree | 81e76f6dbbe94dbeb7bddbbde09bb31f6d6b85f2 /src/client/qwaylandintegration.cpp | |
parent | 7344822dd3991fa4b914531d7e2a42b1c05c1e9d (diff) |
Move xdg-shell-v5 to a plugin
This is the first step in deprecating xdg-shell unstable v5 and making the good
names available for the good names for xdg-shell stable.
Shell initialization has been refactored slightly, so the
QWaylandShellIntegrationFactory actually tries to initialize the shell
integration before returning it. Similarly for the factory method of non-plugin
shells.
Change-Id: I85e60594c4fc03c6f302c04316110aed428d28dc
Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
Diffstat (limited to 'src/client/qwaylandintegration.cpp')
-rw-r--r-- | src/client/qwaylandintegration.cpp | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/src/client/qwaylandintegration.cpp b/src/client/qwaylandintegration.cpp index b804988b2..2a169aca6 100644 --- a/src/client/qwaylandintegration.cpp +++ b/src/client/qwaylandintegration.cpp @@ -77,7 +77,6 @@ #include "qwaylandshellintegration_p.h" #include "qwaylandshellintegrationfactory_p.h" -#include "qwaylandxdgshellintegration_p.h" #include "qwaylandwlshellintegration_p.h" #include "qwaylandxdgshellv6integration_p.h" @@ -409,9 +408,9 @@ void QWaylandIntegration::initializeShellIntegration() } } - if (!mShellIntegration || !mShellIntegration->initialize(mDisplay.data())) { - mShellIntegration.reset(); - qWarning("Failed to load shell integration %s", qPrintable(targetKey)); + if (!mShellIntegration) { + qCWarning(lcQpaWayland) << "Loading shell integration failed."; + qCWarning(lcQpaWayland) << "Attempted to load the following shells" << preferredShells; } } @@ -445,13 +444,12 @@ QWaylandShellIntegration *QWaylandIntegration::createShellIntegration(const QStr { if (integrationName == QLatin1Literal("wl-shell")) { return QWaylandWlShellIntegration::create(mDisplay.data()); - } else if (integrationName == QLatin1Literal("xdg-shell-v5")) { - return QWaylandXdgShellIntegration::create(mDisplay.data()); } else if (integrationName == QLatin1Literal("xdg-shell-v6")) { return QWaylandXdgShellV6Integration::create(mDisplay.data()); } else if (QWaylandShellIntegrationFactory::keys().contains(integrationName)) { - return QWaylandShellIntegrationFactory::create(integrationName, QStringList()); + return QWaylandShellIntegrationFactory::create(integrationName, mDisplay.data()); } else { + qCWarning(lcQpaWayland) << "No shell integration named" << integrationName << "found"; return nullptr; } } |