From 7a35e256bc2c57b41c595fb2c5a46d61bb5fc68f Mon Sep 17 00:00:00 2001 From: ManoloFLTK <41016272+ManoloFLTK@users.noreply.github.com> Date: Sun, 23 Jun 2024 08:05:53 +0200 Subject: Wayland: stop key repeats when focus leaves a window --- src/drivers/Wayland/Fl_Wayland_Screen_Driver.cxx | 1 + 1 file changed, 1 insertion(+) (limited to 'src') diff --git a/src/drivers/Wayland/Fl_Wayland_Screen_Driver.cxx b/src/drivers/Wayland/Fl_Wayland_Screen_Driver.cxx index 8998d4758..d5850e1a3 100644 --- a/src/drivers/Wayland/Fl_Wayland_Screen_Driver.cxx +++ b/src/drivers/Wayland/Fl_Wayland_Screen_Driver.cxx @@ -844,6 +844,7 @@ static void wl_keyboard_leave(void *data, struct wl_keyboard *wl_keyboard, struct Fl_Wayland_Screen_Driver::seat *seat = (struct Fl_Wayland_Screen_Driver::seat*)data; //fprintf(stderr, "keyboard leave fl_win=%p\n", Fl_Wayland_Window_Driver::surface_to_window(surface)); seat->keyboard_surface = NULL; + last_keydown_serial = 0; Fl_Window *win = Fl_Wayland_Window_Driver::surface_to_window(surface); if (!win && Fl::focus()) win = Fl::focus()->top_window(); if (win) Fl::handle(FL_UNFOCUS, win); -- cgit v1.2.3