From 85a64f2934ab7c3f252ec1988c99c53d0fce6e4f Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Mon, 20 May 2024 09:58:48 +0530 Subject: [PATCH] Scrolling with mouse wheel when a selection is active should update the selection Fixes #7543 --- docs/changelog.rst | 2 ++ kitty/mouse.c | 5 ++++- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/docs/changelog.rst b/docs/changelog.rst index f314e9c82..a00e7f075 100644 --- a/docs/changelog.rst +++ b/docs/changelog.rst @@ -90,6 +90,8 @@ Detailed list of changes - Remote control: @ action: Fix some actions being performed on the active window instead of the matched window (:iss:`7438`) +- Scrolling with mouse wheel when a selection is active should update the selection (:iss:`7453`) + 0.34.1 [2024-04-19] ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ diff --git a/kitty/mouse.c b/kitty/mouse.c index 792403de4..82b6f225e 100644 --- a/kitty/mouse.c +++ b/kitty/mouse.c @@ -961,7 +961,10 @@ scroll_event(double xoffset, double yoffset, int flags, int modifiers) { } } } else { - if (screen->linebuf == screen->main_linebuf) screen_history_scroll(screen, abs(s), upwards); + if (screen->linebuf == screen->main_linebuf) { + screen_history_scroll(screen, abs(s), upwards); + if (screen->selections.in_progress) update_drag(w); + } else fake_scroll(w, abs(s), upwards); } }