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