diff options
| author | Daniel Eklöf <daniel@ekloef.se> | 2019-08-04 17:15:50 +0000 |
|---|---|---|
| committer | Daniel Eklöf <daniel@ekloef.se> | 2019-08-04 17:15:50 +0000 |
| commit | 3ae210d4c5100e484b4a3b1cee1c605e15759993 (patch) | |
| tree | 3fef341184058fe46496ebd0647dea72f59a8c40 | |
| parent | scrollback: use scroll damage to speed up scrolling (diff) | |
selection: only disable selection when mouse drag/motion is on
This allows us to select text in e.g. man/less while still being able
to use LESS=--MOUSE (i.e. enable scrolling with mouse).
| -rw-r--r-- | selection.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/selection.c b/selection.c index 92bc7514..7a0d6960 100644 --- a/selection.c +++ b/selection.c @@ -20,7 +20,8 @@ static bool selection_enabled(const struct terminal *term) { - return term->mouse_tracking == MOUSE_NONE; + return (term->mouse_tracking != MOUSE_DRAG && + term->mouse_tracking != MOUSE_MOTION); } static char * |
