diff options
Diffstat (limited to 'src/Compositor.cpp')
| -rw-r--r-- | src/Compositor.cpp | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/src/Compositor.cpp b/src/Compositor.cpp index de01d35a..baa098b0 100644 --- a/src/Compositor.cpp +++ b/src/Compositor.cpp @@ -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; }
\ No newline at end of file |
