diff --git a/thumbnailitem.cpp b/thumbnailitem.cpp index a8524c7a8e..8b98455872 100644 --- a/thumbnailitem.cpp +++ b/thumbnailitem.cpp @@ -25,6 +25,10 @@ along with this program. If not, see . #include "effects.h" #include "workspace.h" #include "composite.h" +#if HAVE_WAYLAND +#include "shell_client.h" +#include "wayland_server.h" +#endif // Qt #include #include @@ -138,7 +142,13 @@ void WindowThumbnailItem::setWId(qulonglong wId) } m_wId = wId; if (m_wId != 0) { - setClient(Workspace::self()->findClient(Predicate::WindowMatch, m_wId)); + AbstractClient *c = Workspace::self()->findClient(Predicate::WindowMatch, m_wId); +#if HAVE_WAYLAND + if (!c && waylandServer()) { + c = waylandServer()->findClient(m_wId); + } +#endif + setClient(c); } else if (m_client) { m_client = NULL; emit clientChanged();