handle layer popups
This commit is contained in:
parent
b0dffc10b7
commit
5d0919fcff
5 changed files with 136 additions and 1 deletions
|
|
@ -310,4 +310,18 @@ bool CCompositor::windowValidMapped(CWindow* pWindow) {
|
|||
return false;
|
||||
|
||||
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;
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue