X-Git-Url: http://dxcluster.org/gitweb/gitweb.cgi?a=blobdiff_plain;f=perl%2FDXChannel.pm;h=f2a1638cdf0c101817bc92a8aa22c795472bf43b;hb=069852202dd430632012090cb749a0b1564655f4;hp=a02edc9ee200c69c5624151dc52f4e278458cc7d;hpb=c675748ded5843f7bbd3819bb550f66b2534193a;p=spider.git diff --git a/perl/DXChannel.pm b/perl/DXChannel.pm index a02edc9e..f2a1638c 100644 --- a/perl/DXChannel.pm +++ b/perl/DXChannel.pm @@ -159,12 +159,15 @@ sub alloc $user->new_buddies unless $user->buddies; $self->{group} = $user->group; $self->{sort} = $user->sort; + $self->{width} = $user->width; } $self->{startt} = $self->{t} = time; $self->{state} = 0; $self->{oldstate} = 0; $self->{lang} = $main::lang if !$self->{lang}; $self->{func} = ""; + $self->{width} ||= 80; + # add in all the dxcc, itu, zone info my @dxcc = Prefix::extract($call); @@ -721,6 +724,8 @@ sub process $dxchan->disconnect; } elsif ($sort eq 'D') { ; # ignored (an echo) + } elsif ($sort eq 'C') { + $dxchan->width($line); # change number of columns } elsif ($sort eq 'G') { $dxchan->enhanced($line); } else { @@ -743,6 +748,20 @@ sub handle_xml return $r; } +sub registered +{ + my $self = shift; + + # the sysop is registered! + return 1 if $self->call eq $main::myalias || $self->call eq $main::mycall; + + if ($main::reqreg) { + return $self->{registered}; + } else { + return 1; + } +} + #no strict; sub AUTOLOAD {