mirror of
https://github.com/hyprwm/Hyprland
synced 2026-01-04 10:30:15 +01:00
compositor: don't iterate over unmapped ls-es in vectorToLS
fixes #9312
This commit is contained in:
parent
5e7292434a
commit
3b99e906df
1 changed files with 2 additions and 2 deletions
|
|
@ -1245,7 +1245,7 @@ void CCompositor::focusSurface(SP<CWLSurfaceResource> pSurface, PHLWINDOW pWindo
|
|||
SP<CWLSurfaceResource> CCompositor::vectorToLayerPopupSurface(const Vector2D& pos, PHLMONITOR monitor, Vector2D* sCoords, PHLLS* ppLayerSurfaceFound) {
|
||||
for (auto const& lsl : monitor->m_aLayerSurfaceLayers | std::views::reverse) {
|
||||
for (auto const& ls : lsl | std::views::reverse) {
|
||||
if (ls->fadingOut || !ls->layerSurface || (ls->layerSurface && !ls->layerSurface->mapped) || ls->alpha->value() == 0.f)
|
||||
if (!ls->mapped || ls->fadingOut || !ls->layerSurface || (ls->layerSurface && !ls->layerSurface->mapped) || ls->alpha->value() == 0.f)
|
||||
continue;
|
||||
|
||||
auto SURFACEAT = ls->popupHead->at(pos, true);
|
||||
|
|
@ -1263,7 +1263,7 @@ SP<CWLSurfaceResource> CCompositor::vectorToLayerPopupSurface(const Vector2D& po
|
|||
|
||||
SP<CWLSurfaceResource> CCompositor::vectorToLayerSurface(const Vector2D& pos, std::vector<PHLLSREF>* layerSurfaces, Vector2D* sCoords, PHLLS* ppLayerSurfaceFound) {
|
||||
for (auto const& ls : *layerSurfaces | std::views::reverse) {
|
||||
if (ls->fadingOut || !ls->layerSurface || (ls->layerSurface && !ls->layerSurface->surface->mapped) || ls->alpha->value() == 0.f)
|
||||
if (!ls->mapped || ls->fadingOut || !ls->layerSurface || (ls->layerSurface && !ls->layerSurface->surface->mapped) || ls->alpha->value() == 0.f)
|
||||
continue;
|
||||
|
||||
auto [surf, local] = ls->layerSurface->surface->at(pos - ls->geometry.pos(), true);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue