ignore Desktops under X11

pull/6/head
Michail Vourlakos 6 years ago
parent d44809eb25
commit 54f1e3576e

@ -322,7 +322,7 @@ bool Windows::isValidFor(WindowId wid) const
return false;
}
return m_windows[wid].isValid();
return m_windows[wid].isValid() && !m_windows[wid].isPlasmaDesktop();
}
QIcon Windows::iconFor(WindowId wid)

@ -464,7 +464,7 @@ bool XWindowInterface::isValidWindow(const KWindowInfo &winfo) const
return true;
}
constexpr auto types = NET::DockMask | NET::MenuMask | NET::SplashMask | NET::PopupMenuMask | NET::NormalMask | NET::DialogMask;
constexpr auto types = NET::DesktopMask | NET::DockMask | NET::MenuMask | NET::SplashMask | NET::PopupMenuMask | NET::NormalMask | NET::DialogMask;
NET::WindowType winType = winfo.windowType(types);
const auto winClass = KWindowInfo(winfo.win(), 0, NET::WM2WindowClass).windowClassName();
@ -473,6 +473,11 @@ bool XWindowInterface::isValidWindow(const KWindowInfo &winfo) const
return false;
}
//! reject desktop window
if (winType != -1 && (winType & NET::Desktop)) {
return false;
}
if (winType == -1) {
// Trying to get more types for verify if the window have any other type
winType = winfo.windowType(~types & NET::AllTypesMask);

Loading…
Cancel
Save