summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorculler <culler>2024-07-31 12:31:21 (GMT)
committerculler <culler>2024-07-31 12:31:21 (GMT)
commitfafe3ad01856e9c46a5dced7ee0c1dec79c292ae (patch)
treee1c8883408355b1e73de398bb07c164a8fac81d9
parent5cc064f539a40629f546c32bc2d4838071c8c851 (diff)
downloadtk-fafe3ad01856e9c46a5dced7ee0c1dec79c292ae.zip
tk-fafe3ad01856e9c46a5dced7ee0c1dec79c292ae.tar.gz
tk-fafe3ad01856e9c46a5dced7ee0c1dec79c292ae.tar.bz2
Backport fix for [7a17cfd1b5] from 9.0
-rw-r--r--win/tkWinX.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/win/tkWinX.c b/win/tkWinX.c
index 2047536..f86b360 100644
--- a/win/tkWinX.c
+++ b/win/tkWinX.c
@@ -1165,7 +1165,7 @@ GenerateXEvent(
event.key.nbytes = 0;
event.x.xkey.state = state;
event.x.xany.serial = scrollCounter++;
- event.x.xkey.keycode = (unsigned int) delta;
+ event.x.xkey.keycode = (unsigned int) (delta & 0xffff);
} else {
event.x.type = MouseWheelEvent;
event.x.xany.send_event = -1;