summaryrefslogtreecommitdiffstats
path: root/window-copy.c
diff options
context:
space:
mode:
authornicm <nicm>2021-01-08 08:22:10 +0000
committernicm <nicm>2021-01-08 08:22:10 +0000
commitb96c5e3687d36cea7b575a7e151326f1b82824d2 (patch)
tree51b85245222b996580bba15d11e2cbfcb989201b /window-copy.c
parent199689954b310a1915f573156f94cb93457c71f9 (diff)
With incremental search, start empty and only repeat the previous search
if the user tries to search again with an empty prompt. This matches emacs behaviour more closely.
Diffstat (limited to 'window-copy.c')
-rw-r--r--window-copy.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/window-copy.c b/window-copy.c
index 4c81cb1f..bfa94aed 100644
--- a/window-copy.c
+++ b/window-copy.c
@@ -2030,6 +2030,8 @@ window_copy_cmd_search_backward_incremental(struct window_copy_cmd_state *cs)
data->timeout = 0;
+ log_debug ("%s: %s", __func__, argument);
+
prefix = *argument++;
if (data->searchx == -1 || data->searchy == -1) {
data->searchx = data->cx;
@@ -2083,6 +2085,8 @@ window_copy_cmd_search_forward_incremental(struct window_copy_cmd_state *cs)
data->timeout = 0;
+ log_debug ("%s: %s", __func__, argument);
+
prefix = *argument++;
if (data->searchx == -1 || data->searchy == -1) {
data->searchx = data->cx;