X-Git-Url: http://dxcluster.net/gitweb/gitweb.cgi?a=blobdiff_plain;f=perl%2FDXChannel.pm;h=b8824cf4d43923290e35ac16f1e58c189bae5790;hb=57a2e501a50d48dcb8915a05b90d0e8e948c999d;hp=45e8d39b9904a3fd87374f4cc742558b39b1de24;hpb=9a12175ae94f37babc48e2ee43484d1423afa3c1;p=spider.git diff --git a/perl/DXChannel.pm b/perl/DXChannel.pm index 45e8d39b..b8824cf4 100644 --- a/perl/DXChannel.pm +++ b/perl/DXChannel.pm @@ -101,6 +101,7 @@ $count = 0; itu => '0,ITU Zone', cq => '0,CQ Zone', enhanced => '5,Enhanced Client,yesno', + gtk => '5,Using GTK,yesno', senddbg => '8,Sending Debug,yesno', width => '0,Column Width', disconnecting => '9,Disconnecting,yesno', @@ -358,7 +359,8 @@ sub send_now my @lines = split /\n/; for (@lines) { $conn->send_now("$sort$call|$_"); - dbg("-> $sort $call $_") if isdbg('chan'); + # debug log it, but not if it is a log message + dbg("-> $sort $call $_") if $sort ne 'L' && isdbg('chan'); } } $self->{t} = time; @@ -381,7 +383,8 @@ sub send_later my @lines = split /\n/; for (@lines) { $conn->send_later("$sort$call|$_"); - dbg("-> $sort $call $_") if isdbg('chan'); + # debug log it, but not if it is a log message + dbg("-> $sort $call $_") if $sort ne 'L' && isdbg('chan'); } } $self->{t} = time; @@ -513,9 +516,11 @@ sub tell_login # sub tell_buddies { - my ($self, $m, $call) = @_; + my ($self, $m, $call, $node) = @_; $call ||= $self->{call}; + $call =~ s/-\d+$//; + $m .= 'n' if $node; # send info to all logged in thingies my @dxchan = get_all_users(); @@ -523,7 +528,7 @@ sub tell_buddies foreach $dxchan (@dxchan) { next if $dxchan == $self; next if $dxchan->{call} eq $main::mycall; - $dxchan->send($dxchan->msg($m, $call)) if grep $_ eq $call, @{$dxchan->{user}->{buddies}} ; + $dxchan->send($dxchan->msg($m, $call, $node)) if grep $_ eq $call, @{$dxchan->{user}->{buddies}} ; } } @@ -722,6 +727,19 @@ sub process } } +sub handle_xml +{ + my $self = shift; + my $r = 0; + + if (DXXml::available()) { + $r = $self->{handle_xml} || 0; + } else { + delete $self->{handle_xml} if exists $self->{handle_xml}; + } + return $r; +} + #no strict; sub AUTOLOAD {