patch 9.1.0348: X11 does not ignore smooth scroll event

Problem:  X11 does not ignore smooth scroll event
          (laniakea64)
Solution: Correctly ignore unwanted smooth scroll events on X11
          (lilydjwg)

fixes #14578
closes: #14583

Signed-off-by: lilydjwg <lilydjwg@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
diff --git a/src/gui_gtk_x11.c b/src/gui_gtk_x11.c
index d4a8b93..4d201fc 100644
--- a/src/gui_gtk_x11.c
+++ b/src/gui_gtk_x11.c
@@ -2152,6 +2152,9 @@
 		    FALSE, vim_modifiers);
 	}
     }
+    else if (event->direction == GDK_SCROLL_SMOOTH && display_type == DT_X11)
+	// for X11 we deal with unsmooth events, and so ignore the smooth ones
+	;
     else
 #undef DT_X11
 #undef DT_WAYLAND