summaryrefslogtreecommitdiffstats
path: root/src/client/qwaylandinputdevice.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/client/qwaylandinputdevice.cpp')
-rw-r--r--src/client/qwaylandinputdevice.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/client/qwaylandinputdevice.cpp b/src/client/qwaylandinputdevice.cpp
index 5be76d90e..c04067688 100644
--- a/src/client/qwaylandinputdevice.cpp
+++ b/src/client/qwaylandinputdevice.cpp
@@ -717,6 +717,11 @@ void QWaylandInputDevice::Keyboard::keyboard_leave(uint32_t time, struct wl_surf
Q_UNUSED(time);
Q_UNUSED(surface);
+ if (surface) {
+ QWaylandWindow *window = QWaylandWindow::fromWlSurface(surface);
+ window->unfocus();
+ }
+
mFocus = NULL;
// Use a callback to set the focus because we may get a leave/enter pair, and