summaryrefslogtreecommitdiff
path: root/src/managers/input/InputManager.cpp
diff options
context:
space:
mode:
authorvaxerski <43317083+vaxerski@users.noreply.github.com>2023-10-06 01:11:47 +0100
committervaxerski <43317083+vaxerski@users.noreply.github.com>2023-10-06 01:11:47 +0100
commit4b3efc73c5d059e828f79952d80ff79c97521c3d (patch)
treea9559258388a6926b1352d223f5af75faee69d68 /src/managers/input/InputManager.cpp
parent24c04a8b7c874ead168bb2418f4325cb8bdaca5b (diff)
events: fixup empty events not being sent on unmap
Ref #3506 https://github.com/hyprwm/Hyprland/issues/3506#issuecomment-1749508111
Diffstat (limited to 'src/managers/input/InputManager.cpp')
-rw-r--r--src/managers/input/InputManager.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/managers/input/InputManager.cpp b/src/managers/input/InputManager.cpp
index fe66b8ba..1b89f8fc 100644
--- a/src/managers/input/InputManager.cpp
+++ b/src/managers/input/InputManager.cpp
@@ -314,9 +314,8 @@ void CInputManager::mouseMoveUnified(uint32_t time, bool refocus) {
wlr_seat_pointer_clear_focus(g_pCompositor->m_sSeat.seat);
- if (refocus) { // if we are forcing a refocus, and we don't find a surface, clear the kb focus too!
+ if (refocus || !g_pCompositor->m_pLastWindow) // if we are forcing a refocus, and we don't find a surface, clear the kb focus too!
g_pCompositor->focusWindow(nullptr);
- }
return;
}