[wayland] Call ShellClient install interface methods consistently
Summary: When we create a new Shellclient there may be a pending relevant interface. For every other case this is handled in WaylandServer, the class responsible for attaching new interfaces at runtime. The only exception is ServerSideDecorationInterface which is handled in the ShellClient constructor. This makes everything consistent. No behavioural changes. Test Plan: Ran unit tests Reviewers: #kwin, zzag Reviewed By: #kwin, zzag Subscribers: kwin Tags: #kwin Differential Revision: https://phabricator.kde.org/D18592icc-effect-5.17.5
parent
f294e7a035
commit
4240c4af05
|
@ -363,10 +363,6 @@ void ShellClient::init()
|
|||
}
|
||||
});
|
||||
setTransient();
|
||||
// check whether we have a ServerSideDecoration
|
||||
if (ServerSideDecorationInterface *deco = ServerSideDecorationInterface::get(s)) {
|
||||
installServerSideDecoration(deco);
|
||||
}
|
||||
|
||||
AbstractClient::updateColorScheme(QString());
|
||||
|
||||
|
|
|
@ -151,6 +151,9 @@ void WaylandServer::createSurface(T *surface)
|
|||
ScreenLocker::KSldApp::self()->lockScreenShown();
|
||||
}
|
||||
auto client = new ShellClient(surface);
|
||||
if (ServerSideDecorationInterface *deco = ServerSideDecorationInterface::get(surface->surface())) {
|
||||
client->installServerSideDecoration(deco);
|
||||
}
|
||||
auto it = std::find_if(m_plasmaShellSurfaces.begin(), m_plasmaShellSurfaces.end(),
|
||||
[client] (PlasmaShellSurfaceInterface *surface) {
|
||||
return client->surface() == surface->surface();
|
||||
|
|
Loading…
Reference in New Issue