WIP RBN
[spider.git] / perl / DXChannel.pm
index 0e543e9cea6f424c9dfe4cc6634b8b97ef7dc74c..6bc67a2ae316f08fd880d2d95eebe71e2821a277 100644 (file)
@@ -62,6 +62,9 @@ $count = 0;
                  here => '0,Here?,yesno',
                  conf => '0,In Conference?,yesno',
                  dx => '0,DX Spots,yesno',
+                 rbn => '0,RBN Spots,yesno',
+                 ft => '0,(RBN) FT4/8 Spots,yesno',
+                 cw => '0,RBN CW Spots,yesno',
                  redirect => '0,Redirect messages to',
                  lang => '0,Language',
                  func => '5,Function',
@@ -427,7 +430,7 @@ sub send                                            # this is always later and always data
        my $call = $self->{call};
 
        foreach my $l (@_) {
-               for (ref $l ? @$l : $l) {
+               for (ref($l) eq 'ARRAY' ? @$l : $l) {
                        my @lines = split /\n/;
                        for (@lines) {
                                $conn->send_later("D$call|$_");
@@ -679,6 +682,11 @@ sub broadcast_list
                        ($filter) = $dxchan->{spotsfilter}->it(@{$fref}) if ref $fref;
                        next unless $filter;
                }
+               if ($sort eq 'rbn') {
+                   next unless $dxchan->{dx}; # this is deliberate!
+                       ($filter) = $dxchan->{spotsfilter}->it(@{$fref}) if ref $fref;
+                       next unless $filter;
+               }
                next if $sort eq 'ann' && !$dxchan->{ann} && $s !~ /^To\s+LOCAL\s+de\s+(?:$main::myalias|$main::mycall)/i;
                next if $sort eq 'wwv' && !$dxchan->{wwv};
                next if $sort eq 'wcy' && !$dxchan->{wcy};