repo: rxvt-unicode-sixel action: commit revision: path_from: revision_from: 681393186d4e8757c8f90231dc750fd2e79874f4: path_to: revision_to:
commit 681393186d4e8757c8f90231dc750fd2e79874f4 Author: Emanuele GiaquintaDate: Sun Jun 8 19:40:20 2014 +0000 Fix Shift+Enter in searchable-scrollback after an unsuccessful search with Up or Down. diff --git a/src/perl/searchable-scrollback b/src/perl/searchable-scrollback
--- a/src/perl/searchable-scrollback
+++ b/src/perl/searchable-scrollback
@@ -105,8 +105,6 @@ sub idle {
sub search {
my ($self, $dir, $row) = @_;
- delete $self->{found};
-
my $search = $self->special_encode ($self->{search});
no re 'eval'; # just to be sure
@@ -117,6 +115,8 @@ sub search {
my $text = $line->t;
if ($text =~ /$re/g) {
+ delete $self->{found};
+
do {
push @{ $self->{found} }, [$line->coord_of ($-[0]), $line->coord_of ($+[0])];
} while $text =~ /$re/g;
@@ -194,6 +194,7 @@ sub tt_write {
$self->{search} =~ s/^\(\?i\)//
if $self->{search} =~ /^\(.*[[:upper:]]/;
+ delete $self->{found};
$self->search (-1, $self->{row});
$self->idle;
-----END OF PAGE-----