emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

feature/pgtk c3a440e: Calculate pixel deltas correctly


From: Po Lu
Subject: feature/pgtk c3a440e: Calculate pixel deltas correctly
Date: Tue, 30 Nov 2021 06:36:40 -0500 (EST)

branch: feature/pgtk
commit c3a440e520d661e0296a7ac2d97abc5e9cd65712
Author: Po Lu <luangruo@yahoo.com>
Commit: Po Lu <luangruo@yahoo.com>

    Calculate pixel deltas correctly
    
    * src/pgtkterm.c (scroll_event): Fix scroll delta
    factor. (bug#52195)
---
 src/pgtkterm.c | 16 ++++++++--------
 1 file changed, 8 insertions(+), 8 deletions(-)

diff --git a/src/pgtkterm.c b/src/pgtkterm.c
index 9814358..0e98c8a 100644
--- a/src/pgtkterm.c
+++ b/src/pgtkterm.c
@@ -6034,8 +6034,8 @@ scroll_event (GtkWidget * widget, GdkEvent * event, 
gpointer * user_data)
          inev.ie.kind = WHEEL_EVENT;
          inev.ie.modifiers |= down_modifier;
          inev.ie.arg = list3 (make_fixnum (nlines),
-                              make_float (-dpyinfo->scroll.acc_x * 10),
-                              make_float (-dpyinfo->scroll.acc_y * 10));
+                              make_float (-dpyinfo->scroll.acc_x * 100),
+                              make_float (-dpyinfo->scroll.acc_y * 100));
          if (!x_coalesce_scroll_events)
            {
              dpyinfo->scroll.acc_y = 0;
@@ -6053,8 +6053,8 @@ scroll_event (GtkWidget * widget, GdkEvent * event, 
gpointer * user_data)
          inev.ie.kind = WHEEL_EVENT;
          inev.ie.modifiers |= up_modifier;
          inev.ie.arg = list3 (make_fixnum (nlines),
-                              make_float (-dpyinfo->scroll.acc_x * 10),
-                              make_float (-dpyinfo->scroll.acc_y * 10));
+                              make_float (-dpyinfo->scroll.acc_x * 100),
+                              make_float (-dpyinfo->scroll.acc_y * 100));
 
          if (!x_coalesce_scroll_events)
            {
@@ -6071,8 +6071,8 @@ scroll_event (GtkWidget * widget, GdkEvent * event, 
gpointer * user_data)
          inev.ie.kind = HORIZ_WHEEL_EVENT;
          inev.ie.modifiers |= up_modifier;
          inev.ie.arg = list3 (make_fixnum (nchars),
-                              make_float (-dpyinfo->scroll.acc_x * 10),
-                              make_float (-dpyinfo->scroll.acc_y * 10));
+                              make_float (-dpyinfo->scroll.acc_x * 100),
+                              make_float (-dpyinfo->scroll.acc_y * 100));
 
          if (x_coalesce_scroll_events)
            dpyinfo->scroll.acc_x -= dpyinfo->scroll.x_per_char * nchars;
@@ -6088,8 +6088,8 @@ scroll_event (GtkWidget * widget, GdkEvent * event, 
gpointer * user_data)
          inev.ie.kind = HORIZ_WHEEL_EVENT;
          inev.ie.modifiers |= down_modifier;
          inev.ie.arg = list3 (make_fixnum (nchars),
-                              make_float (-dpyinfo->scroll.acc_x * 10),
-                              make_float (-dpyinfo->scroll.acc_y * 10));
+                              make_float (-dpyinfo->scroll.acc_x * 100),
+                              make_float (-dpyinfo->scroll.acc_y * 100));
 
          if (x_coalesce_scroll_events)
            dpyinfo->scroll.acc_x -= -dpyinfo->scroll.x_per_char * nchars;



reply via email to

[Prev in Thread] Current Thread [Next in Thread]