');
+ url=data1[1];
+ ext=data1[2];
+ urlparts=url.split('.');
+ mime=urlparts[urlparts.length-1];
+ if (typeof(mime)=="undefined") { mime=''; }
+ if ((mime!='') && (ext!='true')) {
+ parent.mapout.document.write
+ (' '+
+ ' ');
+ }
+ parent.mapout.document.write(''+k+' | ');
data2=obj[i].split('&');
parent.mapout.document.write('');
+
+ if (data1[3]=='start') {
+ parent.mapout.document.writeln('Start | ');
+ }
+ if (data1[3]=='finish') {
+ parent.mapout.document.writeln('Finish | ');
+ }
parent.mapout.document.write(
'Title: | '+data1[0]+' | ');
parent.mapout.document.write(
@@ -1883,7 +2354,7 @@ function simpletabledraw() {
// ---------------------------------- Sort objects to straighten graph or table
function sortobjs() {
- message("Sorting Resources");
+ message("Sorting Resources: "+funny);
var k;
var ij;
var dol;
@@ -1901,7 +2372,9 @@ function sortobjs() {
}
if (objsort.length==0) { return ''; }
for (k=1;kallcolmax) { allcolmax=thiscolmax; }
thiscolmax=1;
}
kj=rowcont.length-1;
- obj[thisnewobj]='b&'+kj+'&'+thiscolmax+':0:0:0';
+ obj[thisnewobj]='b&'+kj+'&'+thiscolmax+':0:0:0';
+ if (thiscolmax>allcolmax) { allcolmax=thiscolmax; }
}
for (k=0;k');
var k;
for (k=0;k');
+ data2=data1[k].split(':').join(':').split('<:>');
if (data2[0]=='graphdef') { graphdef=data2[1]; }
if (data2[0]=='maxcol') { maxcol=1*data2[1]; }
if (data2[0]=='maxrow') { maxrow=1*data2[1]; }
if (data2[0]=='obj') { obj[data2[1]]=data2[2]; }
if (data2[0]=='objcont') { objcont[data2[1]]=data2[2]; }
if (data2[0]=='objlinks') { objlinks[data2[1]]=data2[2]; }
+ if (data2[0]=='objparms') {
+ if (typeof(objparms[data2[1]])=="undefined") {
+ objparms[data2[1]]=data2[2];
+ } else {
+ objparms[data2[1]]+=':'+data2[2];
+ }
+ }
if (data2[0]=='rowcont') { rowcont[data2[1]]=data2[2]; }
if (data2[0]=='row') { row[data2[1]]=1*data2[2]; }
if (data2[0]=='col') { col[data2[1]]=1*data2[2]; }
+ if (data2[0]=='mode') { mode=data2[1]; }
if (data2[0]=='tablemode') { tablemode=1*data2[1]; }
if (data2[0]=='zscale') { zscale=1*data2[1]; }
}
}
+ if (graphdef=='yes') {
+ for (k=1;k<=maxrow;k++) {
+ if (typeof(rowcont[k])=="undefined") { rowcont[k]=''; }
+ }
+ }
+}
+
+// -------------------------------------------------------------- Parameter set
+
+function setparms(resid) {
+ var options="scrollbars=1,resizable=1,menubar=0";
+ parmflag=1;
+ data1=objcont[resid].split(':');
+ parm=open("/adm/ratparms?url="+data1[1]+"&parms="+objparms[resid]+
+ "&resid="+resid,"parmout",options);
+ parm.focus();
}
// -------------------------------------------------------------- Undo function
@@ -2067,7 +2581,7 @@ function undo() {
undopointer--;
parent.server.document.forms.storage.output.value
=undostack[undopointer];
- load();
+ finishload();
undopointer--;
draw();
stored=0;
@@ -2083,7 +2597,7 @@ function redo() {
undopointer++;
parent.server.document.forms.storage.output.value
=undostack[undopointer];
- load();
+ finishload();
undopointer--;
draw();
stored=0;
@@ -2101,12 +2615,92 @@ function revert() {
}
}
+// ---------------------------------------------------------------- Wheelswitch
+
+function wheelswitch() {
+ if (funny=='|') {
+ funny='/';
+ } else {
+ if (funny=='/') {
+ funny='-';
+ } else {
+ if (funny=='-') {
+ funny='\\';
+ } else {
+ if (funny=='\\') { funny='|'; }
+ }
+ }
+ }
+}
+
+// --------------------------------------------- Checks if server frame defined
+
+function checkdef() {
+ if (parent.flag==1) {
+ srvloaded();
+ }
+ if ((finishdone==0) && (tim==0)) { setTimeout('checkdef()',100); }
+}
+
+// ---------------------------------------------------------- The wait function
+
+function wait() {
+ if ((finishdone==1) || (tim==1)) {
+ if (tim==0) {
+ clearTimeout(canceltim);
+ if (reqaction=='save') { finishsave(); }
+ if (reqaction=='load') { finishload(); draw(); }
+ } else {
+ alert("Server Communication Timed Out.");
+ }
+ } else {
+ wheelswitch();
+ message('Waiting for server reply: '+funny);
+ setTimeout('wait();',100);
+ }
+}
+
+// ---------------------------------------------------------- Schedule function
+
+function schedule(action) {
+ reqaction=action;
+ tim=0;
+ finishdone=0;
+ canceltim=setTimeout('tim=1;',20000);
+ checkdef();
+ wait();
+}
+
+// ----------------------------------------------------- launch indexer browser
+
+function groupsearch() {
+ alert('not yet implemented');
+}
+
+function groupimport() {
+ idxcheck('groupimport');
+}
+
// -------------------------------------------------------------- Store changes
function storechange() {
+ var k;
+ parent.flag=0;
parent.server.document.forms.storage.submit();
+ schedule('save');
+}
+
+function finishsave() {
+ finishload();
+ draw();
stored=1;
- alert("Stored changes");
+}
+
+// --------------------------------------- Gets called when submission finished
+
+function srvloaded() {
+ finishdone=1;
+ message("Server replied.");
}
// ---------------------------------------------------------------- Toggle Mode
@@ -2131,41 +2725,50 @@ function togglemode() {
function main() {
if (mainrun==0) {
+ infopen();
+ infoclear();
load();
- draw();
stored=1;
mainrun=1;
}
}
-// ------------------------------------------------------------- Save on leave?
+// ---------------------------------------------------------- Close the window?
function leave() {
- if (stored==0) {
- if (confirm('Store changes?')) {
- storechange();
- }
+ if (!inf.closed) {
+ inf.close();
+ }
+ if (srch && !srch.closed) {
+ srchclose();
+ }
+ if (idx && !idx.closed) {
+ srchclose();
}
}
-
-Toggle Display Mode
-Zoom Out
-Zoom In
-Condense
-Straighten
-Revert
-Undo
-Redo
-Store
+
+
+
-
-
-
-
-
|