--- rat/client/Attic/code.html 2001/05/28 22:23:00 1.32 +++ rat/client/Attic/code.html 2001/06/02 17:19:53 1.33 @@ -14,6 +14,7 @@ Resource Assembly Tool March/April 01 Scott Harrison 04/20 Gerd Kortemeyer 04/30 Scott Harrison +05/31 Scott Harrison --> @@ -79,10 +80,13 @@ var srch; var srchflag=-1; // 1 means currently open // 0 means closed (but has been open) // -1 means never yet opened/defined +var srchmode=''; + var idx; var idxflag=-1; // 1 means currently open // 0 means closed (but has been open) // -1 means never yet opened/defined +var idxmode=''; function testfunction() { inf.document.forms.resinfo.elements.t.value="ABC"; @@ -1509,17 +1513,19 @@ function srchclose() { // -------------------------------------------------------- Open indexer window -function idxopen() { +function idxopen(mode) { var options="scrollbars=1,resizable=1,menubar=0"; + idxmode=mode; idxflag=1; - idx=open("/res?catalogmode=interactive","idxout",options); + idx=open("/res?catalogmode="+mode,"idxout",options); idx.focus(); } // --------------------------------------------------------- Open search window -function srchopen() { +function srchopen(mode) { var options="scrollbars=1,resizable=1,menubar=0"; + srchmode=mode; srchflag=1; srch=open("/adm/searchcat?catalogmode=interactive","srchout",options); srch.focus(); @@ -1533,8 +1539,8 @@ function search() { // ------------------------------------------------------- Do srch status check -function srchcheck() { - if (!srch || srch.closed) { +function srchcheck(mode) { + if (!srch || srch.closed || srchmode!=mode) { srchopen(); } srch.focus(); @@ -1542,9 +1548,9 @@ function srchcheck() { // -------------------------------------------------------- Do idx status check -function idxcheck() { - if (!idx || idx.closed) { - idxopen(); +function idxcheck(mode) { + if (!idx || idx.closed || idxmode!=mode) { + idxopen(mode); } idx.focus(); } @@ -1645,9 +1651,9 @@ function handler(infostr) { +'