Diff for /loncom/interface/lonmenu.pm between versions 1.75 and 1.76

version 1.75, 2003/06/05 00:01:45 version 1.76, 2003/06/06 02:24:49
Line 158  ENDINLINEMENU Line 158  ENDINLINEMENU
     }      }
 }  }
   
 # ===== Early call to LONCAPAreg for long-running pages, preferably used right   
 # ===== before $r->rflush()  
   
 sub regflush {  
     return '<script type="text/javascript">'.&loadevents.'</script>';  
 }  
   
 # ====================================== This gets called in the header section  # ====================================== This gets called in the header section
   
 sub registerurl {  sub registerurl {
Line 187  sub registerurl { Line 180  sub registerurl {
         ((($ENV{'request.publicaccess'}) ||           ((($ENV{'request.publicaccess'}) || 
          (!&Apache::lonnet::is_on_map($ENV{'REQUEST_URI'}))) &&           (!&Apache::lonnet::is_on_map($ENV{'REQUEST_URI'}))) &&
         (!$forcereg))) {          (!$forcereg))) {
         my $loadfunction='';    return $result.
         my $inlineloadfunction='';            '<script type="text/javascript">function LONCAPAreg(){;} function LONCAPAstale(){}</script>'.$force_title;
         my $unloadfunction='';  
         unless (($ENV{'browser.interface'} eq 'textual') ||  
                 ($ENV{'environment.remote'} eq 'off') ||  
                 ($ENV{'request.publicaccess'})) {  
     my $reopen=&Apache::lonmenu::reopenmenu();  
      $loadfunction='swmenu='.$reopen.'swmenu.windowloaded(self.name);window.focus();';  
             $inlineloadfunction=&regflush();  
      $unloadfunction='swmenu='.$reopen.'swmenu.windowunloaded(self.name);';  
         }   
  return $result.(<<ENDFUNCTIONS);  
 <script type="text/javascript">  
 function LONCAPAreg() {  
    $loadfunction  
 }   
   
 function LONCAPAstale() {  
    $unloadfunction  
 }  
 </script>  
 $inlineloadfunction  
 $force_title  
 ENDFUNCTIONS  
     }      }
 # Graphical display after login only  # Graphical display after login only
     if ($Apache::lonxml::registered && !$forcereg) { return ''; }      if ($Apache::lonxml::registered && !$forcereg) { return ''; }
Line 398  ENDREGTEXT Line 369  ENDREGTEXT
 <script language="JavaScript">  <script language="JavaScript">
 // BEGIN LON-CAPA Internal  // BEGIN LON-CAPA Internal
 var swmenu=null;  var swmenu=null;
 swmenu=$reopen;  
 swmenu.windowloaded(self.name);  
   
     function LONCAPAreg() {      function LONCAPAreg() {
   swmenu=$reopen;    swmenu=$reopen;
           swmenu.windowloaded(self.name);  
           swmenu.clearTimeout(swmenu.menucltim);            swmenu.clearTimeout(swmenu.menucltim);
           $timesync            $timesync
           $newmail            $newmail
Line 431  swmenu.windowloaded(self.name); Line 399  swmenu.windowloaded(self.name);
  'clearbut(2,1);clearbut(2,3);clearbut(8,1);clearbut(8,2);clearbut(8,3);'+   'clearbut(2,1);clearbut(2,3);clearbut(8,1);clearbut(8,2);clearbut(8,3);'+
  'clearbut(9,1);clearbut(9,2);clearbut(9,3);clearbut(6,3);clearbut(6,1)',   'clearbut(9,1);clearbut(9,2);clearbut(9,3);clearbut(6,3);clearbut(6,1)',
   2000);    2000);
           swmenu.windowunloaded(self.name);  
       }        }
   
 // END LON-CAPA Internal  // END LON-CAPA Internal
Line 455  var swmenu=null; Line 422  var swmenu=null;
   
     function LONCAPAreg() {      function LONCAPAreg() {
   swmenu=$reopen    swmenu=$reopen
   swmenu.windowloaded(self.name);  
           $timesync            $timesync
           swmenu.currentStale=1;            swmenu.currentStale=1;
           swmenu.clearbut(2,1);            swmenu.clearbut(2,1);
Line 472  var swmenu=null; Line 438  var swmenu=null;
     }      }
   
     function LONCAPAstale() {      function LONCAPAstale() {
    swmenu=$reopen  
   swmenu.windowunloaded(self.name);    
     }      }
   
 // END LON-CAPA Internal  // END LON-CAPA Internal

Removed from v.1.75  
changed lines
  Added in v.1.76


FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>