graesslin requested changes to this revision.
graesslin added inline comments.
This revision now requires changes to proceed.

INLINE COMMENTS

> shell_client.cpp:1319
> +    if (m_XdgForeign) {
> +        s = m_XdgForeign->transientFor(surface());
> +    }

I would delegate this to waylandServer, so that there is no need to pass the 
foreign global to each ShellClient.

> shell_client.cpp:1403
> +    m_XdgForeign = foreign;
> +    connect(m_XdgForeign, 
> &KWayland::Server::XdgForeignUnstableInterface::transientChanged, this, 
> &ShellClient::setTransient);
> +    setTransient();

This connect could be done in waylandServer then there would not be a reason to 
have this method at all.

> shell_client.h:129
>      void 
> installServerSideDecoration(KWayland::Server::ServerSideDecorationInterface 
> *decoration);
> +    void 
> installXdgForeignUnstableInterface(KWayland::Server::XdgForeignUnstableInterface
>  *foreign);
>  

Please drop the UnstableInterface.

> shell_client.h:212
>      KWayland::Server::ServerSideDecorationInterface *m_serverDecoration = 
> nullptr;
> +    QPointer<KWayland::Server::XdgForeignUnstableInterface> m_XdgForeign = 
> nullptr;
>      bool m_userNoBorder = false;

No need to explicitly set the QPointer to nullptr.

> wayland_server.cpp:162
> +    client->installXdgForeignUnstableInterface(m_XdgForeign);
>  }
>  

Why is the xdgForeign passed to the client?

REPOSITORY
  R108 KWin

REVISION DETAIL
  https://phabricator.kde.org/D7521

To: mart, #plasma, graesslin
Cc: graesslin, davidedmundson, plasma-devel, kwin, #kwin, ZrenBot, progwolff, 
lesliezhai, ali-mohamed, hardening, jensreuterberg, abetts, sebas, apol, mart, 
lukas

Reply via email to