rework popups completely

This commit is contained in:
vaxerski
2022-03-27 17:25:20 +02:00
parent 4c3b9ae207
commit ad36a9dc9e
11 changed files with 314 additions and 285 deletions

View File

@@ -365,20 +365,6 @@ bool CCompositor::windowValidMapped(CWindow* pWindow) {
return true;
}
SLayerSurface* CCompositor::getLayerForPopup(SLayerPopup* pPopup) {
auto CurrentPopup = pPopup;
while (CurrentPopup->parentPopup != nullptr) {
for (auto& p : g_pCompositor->m_lLayerPopups) {
if (p.popup == CurrentPopup->parentPopup) {
CurrentPopup = &p;
break;
}
}
}
return CurrentPopup->parentSurface;
}
CWindow* CCompositor::getWindowForPopup(wlr_xdg_popup* popup) {
for (auto& p : m_lXDGPopups) {
if (p.popup == popup)