detail changes in console
authordjk <djk>
Fri, 2 Jul 1999 11:35:03 +0000 (11:35 +0000)
committerdjk <djk>
Fri, 2 Jul 1999 11:35:03 +0000 (11:35 +0000)
Changes
cmd/connect.pl
perl/console.pl

diff --git a/Changes b/Changes
index 9d98937efd682e1c895fed5003e4b9d724cc13ec..42289542cc8cf600365ea49dbffd16cb31ee9798 100644 (file)
--- a/Changes
+++ b/Changes
@@ -1,9 +1,13 @@
+01Jul99=======================================================================
+1. Altered priv to 5 for connect.pl to match disconnect for nodes
 29Jun99=======================================================================
 1. fixed merge command that I broke.
 2. added some randomness in waittimes for aborted outgoing messages 
 3. Message Queuing now only occurs every 5 minutes (configurable if anyone 
 wants to write the command for doing it) nad on receipt of a PC16. This is
 a further attempt at sorting the crossing of messages!
+4. a PC33 will cause another attempt at queuing. If you are on a roll, keep
+going!
 28Jun99=======================================================================
 1. console.pl now works with history and editting.
 2. added scrolling to stuff sent by the cluster.
index df9a42389c73dc38400c0b8f4b12dd3904855da0..14f94bb3e4a93c31924091dc7b4b500dac28ff6f 100644 (file)
@@ -5,7 +5,7 @@ my $self = shift;
 my $call = uc shift;
 my $lccall = lc $call;
 
-return (0) if $self->priv < 8;
+return (1, $self->msg('e5')) if $self->priv < 5;
 return (1, $self->msg('e6')) unless $call gt ' ';
 return (1, $self->msg('already', $call)) if DXChannel->get($call);
 return (1, $self->msg('conscript', $lccall)) unless -e "$main::root/connect/$lccall";
index 14c945a58987edabecd084078caf58eedca9ed38..0cb15bd0fbc0171446f40fde6151ee100621f8d7 100755 (executable)
@@ -118,6 +118,15 @@ sub show_screen
        $top->refresh();
 }
 
+# add a line to the end of the top screen
+sub addtotop
+{
+       my $inbuf = shift;
+       push @shistory, $inbuf;
+       shift @shistory if @shistory > $maxshist;
+       show_screen();
+}
+
 # handle incoming messages
 sub rec_socket
 {
@@ -129,10 +138,7 @@ sub rec_socket
                my ($sort, $call, $line) = $msg =~ /^(\w)(\S+)\|(.*)$/;
                
                if ($sort eq 'D') {
-                       push @shistory, $line;
-                       shift @shistory if @shistory > $maxshist;
-#                      $spos = @shistory if $spos >= @shistory - 1;
-                       show_screen();
+                       addtotop($line);
                } elsif ($sort eq 'Z') { # end, disconnect, go, away .....
                        cease(0);
                }         
@@ -164,6 +170,9 @@ sub rec_stdin
                                $bot->clrtoeol();
                                $bot->addstr(substr($inbuf, 0, COLS));
                        }
+
+                       # add it to the monitor window
+                       addtotop($inbuf) if $inbuf;
                
                        # send it to the cluster
                        $inbuf = " " unless $inbuf;
@@ -252,11 +261,8 @@ sub rec_stdin
                        $pos++;
                        $lth++;
                } elsif ($r eq "\014" || $r eq "\022") {
-                       $top->touchwin();
-                       $bot->touchwin();
-                       $scr->touchwin();
-                       $scr->refresh();
-                       $top->refresh();
+#                      curscr()->refresh();
+                       return;
                } elsif ($r eq "\013") {
                        $inbuf = substr($inbuf, 0, $pos);
                        $lth = length $inbuf;