Use selection_make instead of selection_grab.

For some reason selection_grab was not working with my urxvt setup,
however the selection_beg, selection_end and selection_make trio worked
fine.

Signed-off-by: Tim Smart <tim@fostle.com>
This commit is contained in:
Tim Smart 2012-01-18 19:40:38 +13:00
parent d48894fc14
commit 447842ee48

View File

@ -101,8 +101,12 @@ sub key_press {
$self->exec_async(@{$self->{browser}}, ${$self->{found}[$self->{n}]}[4]); $self->exec_async(@{$self->{browser}}, ${$self->{found}[$self->{n}]}[4]);
deactivate($self) unless $char eq 'o'; deactivate($self) unless $char eq 'o';
} elsif ($char eq 'y') { } elsif ($char eq 'y') {
$self->selection(${$self->{found}[$self->{n}]}[4]); my $found = $self->{found}[$self->{n}];
$self->selection_grab($event->{time}); $self->selection_beg(${$found}[0], ${$found}[1]);
$self->selection_end(${$found}[2], ${$found}[3]);
$self->selection_make($event->{time});
$self->selection_beg(1, 0);
$self->selection_end(1, 0);
deactivate($self); deactivate($self);
} elsif ($char eq 'k' || $keysym == 0xff52 || $keysym == 0xff51) { } elsif ($char eq 'k' || $keysym == 0xff52 || $keysym == 0xff51) {
select_next($self, -1); select_next($self, -1);