diff options
author | Po Lu <luangruo@yahoo.com> | 2021-12-08 10:04:31 +0800 |
---|---|---|
committer | Po Lu <luangruo@yahoo.com> | 2021-12-08 10:04:31 +0800 |
commit | 5671709590e778cb3af83b2aa33bd112e1fd66fe (patch) | |
tree | 88de24ea921f7efc74215a3088e172ed947ff762 /src/xwidget.c | |
parent | 176c63287ffdf56634984494f6610102737f393e (diff) | |
download | emacs-5671709590e778cb3af83b2aa33bd112e1fd66fe.tar.gz emacs-5671709590e778cb3af83b2aa33bd112e1fd66fe.tar.bz2 emacs-5671709590e778cb3af83b2aa33bd112e1fd66fe.zip |
Send scroll stop events to xwidgets correctly
* src/xterm.c (handle_one_xevent): Record stop events manually.
* src/xwidget.h (xwidget_scroll):
* src/xwidget.c (xwidget_scroll): New parameter `stop_p'.
Diffstat (limited to 'src/xwidget.c')
-rw-r--r-- | src/xwidget.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/src/xwidget.c b/src/xwidget.c index 9b9f364ce40..d8510ef9286 100644 --- a/src/xwidget.c +++ b/src/xwidget.c @@ -1062,7 +1062,8 @@ xwidget_motion_notify (struct xwidget_view *view, void xwidget_scroll (struct xwidget_view *view, double x, double y, - double dx, double dy, uint state, Time time) + double dx, double dy, uint state, Time time, + bool stop_p) { GdkEvent *xg_event; GtkWidget *target; @@ -1097,9 +1098,7 @@ xwidget_scroll (struct xwidget_view *view, double x, double y, xg_event->scroll.delta_x = dx; xg_event->scroll.delta_y = dy; xg_event->scroll.device = find_suitable_pointer (view->frame); - - if (!(fabs (dx) > 0) || !(fabs (dy) > 0)) - xg_event->scroll.is_stop = TRUE; + xg_event->scroll.is_stop = stop_p; g_object_ref (xg_event->any.window); |