Try to fix hilight.
This commit is contained in:
parent
846d406f52
commit
19f0b048f8
8
sound.pl
8
sound.pl
@ -233,15 +233,16 @@ sub hilight {
|
|||||||
my ($dest, $text, $stripped) = @_;
|
my ($dest, $text, $stripped) = @_;
|
||||||
my $server = $dest->{server};
|
my $server = $dest->{server};
|
||||||
my $window = Irssi::active_server();
|
my $window = Irssi::active_server();
|
||||||
|
if ($server && ! Irssi::settings_get_bool("sounds")) {
|
||||||
|
return;
|
||||||
|
} else {
|
||||||
if (!($server &&
|
if (!($server &&
|
||||||
$dest->{level} & (MSGLEVEL_HILIGHT) &&
|
$dest->{level} & (MSGLEVEL_HILIGHT) &&
|
||||||
$server->ischannel($dest->{target}) &&
|
$server->ischannel($dest->{target}) &&
|
||||||
$window->{refnum} != $dest->{window}->{refnum})) {
|
$window->{refnum} != $dest->{window}->{refnum})) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if ($server && ! Irssi::settings_get_bool("sounds")) {
|
}
|
||||||
return;;
|
|
||||||
} else {
|
|
||||||
if (my $hilightcmd = Irssi::settings_get_str("hilight_sound_command")) {
|
if (my $hilightcmd = Irssi::settings_get_str("hilight_sound_command")) {
|
||||||
if ($flood_protect) {
|
if ($flood_protect) {
|
||||||
my $sound_flood = Irssi::settings_get_int('sound_flood');
|
my $sound_flood = Irssi::settings_get_int('sound_flood');
|
||||||
@ -253,7 +254,6 @@ $window->{refnum} != $dest->{window}->{refnum})) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
#add settings and defaults
|
#add settings and defaults
|
||||||
Irssi::settings_add_bool("lookandfeel", "sounds", 1);
|
Irssi::settings_add_bool("lookandfeel", "sounds", 1);
|
||||||
|
Loading…
Reference in New Issue
Block a user