Send wheel events to program when it asks to grab mouse, even in main screen
This matches behavior of other terminals and I dont have a strong preference either way. Fixes #2939
This commit is contained in:
parent
601d37aa3d
commit
0bff30e954
@ -24,6 +24,10 @@ To update |kitty|, :doc:`follow the instructions <binary>`.
|
|||||||
- Allow specifying watchers in session files and via a command line argument
|
- Allow specifying watchers in session files and via a command line argument
|
||||||
(:iss:`2933`)
|
(:iss:`2933`)
|
||||||
|
|
||||||
|
- When in the main screen and a program grabs the mouse, do not use the scroll
|
||||||
|
wheel events to scroll the scrollback buffer, instead send them to the
|
||||||
|
program (:iss:`2939`)
|
||||||
|
|
||||||
|
|
||||||
0.18.3 [2020-08-11]
|
0.18.3 [2020-08-11]
|
||||||
-------------------
|
-------------------
|
||||||
|
|||||||
@ -702,9 +702,6 @@ scroll_event(double UNUSED xoffset, double yoffset, int flags, int modifiers) {
|
|||||||
}
|
}
|
||||||
if (s == 0) return;
|
if (s == 0) return;
|
||||||
bool upwards = s > 0;
|
bool upwards = s > 0;
|
||||||
if (screen->linebuf == screen->main_linebuf) {
|
|
||||||
screen_history_scroll(screen, abs(s), upwards);
|
|
||||||
} else {
|
|
||||||
if (screen->modes.mouse_tracking_mode) {
|
if (screen->modes.mouse_tracking_mode) {
|
||||||
int sz = encode_mouse_scroll(w, upwards, modifiers);
|
int sz = encode_mouse_scroll(w, upwards, modifiers);
|
||||||
if (sz > 0) {
|
if (sz > 0) {
|
||||||
@ -714,8 +711,8 @@ scroll_event(double UNUSED xoffset, double yoffset, int flags, int modifiers) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
fake_scroll(w, abs(s), upwards);
|
if (screen->linebuf == screen->main_linebuf) screen_history_scroll(screen, abs(s), upwards);
|
||||||
}
|
else fake_scroll(w, abs(s), upwards);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user