reset focus on lock surface destroy

This commit is contained in:
vaxerski 2023-02-18 01:09:01 +00:00
parent be2e4d9dd1
commit b944386ca5

View file

@ -36,6 +36,9 @@ static void handleSurfaceDestroy(void* owner, void* data) {
PSURFACE->hyprListener_destroy.removeCallback(); PSURFACE->hyprListener_destroy.removeCallback();
PSURFACE->hyprListener_map.removeCallback(); PSURFACE->hyprListener_map.removeCallback();
if (PSURFACE->pWlrLockSurface->surface == g_pCompositor->m_pLastFocus)
g_pCompositor->m_pLastFocus = nullptr;
g_pSessionLockManager->removeSessionLockSurface(PSURFACE); g_pSessionLockManager->removeSessionLockSurface(PSURFACE);
} }