File:  [LON-CAPA] / doc / window_handling.txt
Revision 1.3: download - view: text, annotated - select for diffs
Mon Apr 30 17:16:21 2001 UTC (22 years, 11 months ago) by harris41
Branches: MAIN
CVS tags: HEAD
minor changes

    1: The following files have window handling:
    2: (find . -type f | xargs grep -s -l -i '<script' | xargs grep -s -l -i '\.open')
    3: 
    4: ./loncom/homework/lonhomework.pm
    5: ./loncom/html/res/adm/pages/annotator/admannotations.pm
    6: ./loncom/html/res/adm/pages/homeworkmenu.html
    7: ./loncom/html/res/adm/pages/menu.html
    8: ./loncom/html/res/adm/pages/bookmarkmenu/bookmarkpal_old.html
    9: ./loncom/interface/londropadd.pm
   10: ./loncom/interface/lonmenu.pm
   11: ./loncom/interface/lonnavmaps.pm
   12: ./loncom/interface/lonparmset.pm
   13: ./loncom/interface/loncreateuser.pm
   14: ./loncom/xml/scripttag.pm
   15: ./rat/client/code.html
   16: ./rat/client/parameter.html
   17: 
   18: things that refer to loncapaclient
   19: find . -type f | xargs grep loncapaclient
   20: 
   21: #########################################
   22: # ./loncom/html/res/adm/pages/menu.html
   23: #
   24: 
   25: clienthost=window.location.host;
   26: clientwindow=opener;
   27: 
   28: function windowcheck() {
   29:    if (clientwindow.closed) {
   30:       clientwindow=window.open("http://"+clienthost+"/"); 
   31:    }
   32:    clientwindow.name='loncapaclient';
   33: }
   34: 
   35: function logout () {
   36:    windowcheck();
   37:    if (clientwindow.status!='MenuControl:nologout')
   38:    {   
   39:       clientwindow.window.location.href="http://"+clienthost+"/adm/logout";
   40:    }
   41: }
   42: 
   43: 
   44: 
   45: The way that children windows of 
   46: loncapaclient should work:
   47: 
   48: * need to track if they have ever been opened
   49: * if not,
   50:    * open when needed
   51:    * never refer to any object properties
   52:      * which also means never close
   53: * if currently open,
   54:    * just focus when needed
   55:    * close when needed
   56:    * can refer to object properties
   57: * if have been closed,
   58:    * can refer to object properties
   59: 
   60: The way loncapaclient window "should" work.
   61: * lonxml makes exceptions for some URI=resources like
   62:  * /res/adm/pages/menu.html
   63:  * bookmark stuff.html
   64: * lonxml should by default
   65:  * a script command should follow the body tag
   66:    and 
   67:    * name the window (loncapaclientURICHECKSUM)
   68:    * tell remote control it exists
   69:    * remote control checks clientwindow (opener)
   70:      and if opener.name is loncapaclientURICHECKSUM
   71:      it changes this to loncapaclient
   72: 

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