//---------------------------------------------------------------------------
// This script is based on the work of Dieter Bungers - http://www.infovation.de
// The original example for the "Cross Browser Expanding and Collapsing TOC"
// was published on http://www.siteexperts.com/tips/techniques/ts03/index.htm
//---------------------------------------------------------------------------

var tocTab = new Array();var ir=0;
tocTab[ir++] = new Array ("1", " ", "concept.htm", "", "cicon3.gif", "cicon4.gif");
tocTab[ir++] = new Array ("1.1", "Database", "database.htm", "", "cicon17.gif", "cicon17.gif");
tocTab[ir++] = new Array ("1.2", "Network", "network.htm", "", "cicon17.gif", "cicon17.gif");
tocTab[ir++] = new Array ("1.3", "Licensing", "licensing.htm", "", "cicon1.gif", "cicon2.gif");
tocTab[ir++] = new Array ("1.3.1", "Open Subscription", "opensubscription.htm", "", "cicon35.gif", "cicon35.gif");
tocTab[ir++] = new Array ("1.3.2", "Runtime License", "runtimelicense.htm", "", "cicon35.gif", "cicon35.gif");
tocTab[ir++] = new Array ("1.3.3", "Runtime License Plus", "runtimelicenseplus.htm", "", "cicon35.gif", "cicon35.gif");
tocTab[ir++] = new Array ("1.4", "User Profiles", "visualappearance.htm", "", "cicon17.gif", "cicon17.gif");
tocTab[ir++] = new Array ("1.5", "PMS Integration", "interfaces.htm", "", "cicon17.gif", "cicon17.gif");
tocTab[ir++] = new Array ("1.6", "Image Import", "imageimport.htm", "", "cicon17.gif", "cicon17.gif");
tocTab[ir++] = new Array ("1.7", "Languages", "languages.htm", "", "cicon17.gif", "cicon17.gif");
tocTab[ir++] = new Array ("1.8", "System Recommendations", "systemrequirements.htm", "", "cicon1.gif", "cicon2.gif");
tocTab[ir++] = new Array ("1.8.1", "Database Server", "server.htm", "", "cicon35.gif", "cicon35.gif");
tocTab[ir++] = new Array ("1.8.2", "Network Workstation", "workstations.htm", "", "cicon35.gif", "cicon35.gif");
tocTab[ir++] = new Array ("1.8.3", "Stand alone Workstation", "stand_aloneworkstation.htm", "", "cicon35.gif", "cicon35.gif");
tocTab[ir++] = new Array ("1.8.4", "Other Components", "periphery.htm", "", "cicon35.gif", "cicon35.gif");
tocTab[ir++] = new Array ("1.9", "", "placeholder.htm", "", "cicon42.gif", "cicon42.gif");
tocTab[ir++] = new Array ("2", " ", "functionality.htm", "", "cicon7.gif", "cicon8.gif");
tocTab[ir++] = new Array ("2.1", "Visual Diagnostics", "overview.htm", "", "cicon1.gif", "cicon2.gif");
tocTab[ir++] = new Array ("2.1.1", "Image Types", "imagetypelibrary.htm", "", "cicon1.gif", "cicon2.gif");
tocTab[ir++] = new Array ("2.1.1.1", "Clinical Photos", "clinicalphotos.htm", "", "cicon1.gif", "cicon2.gif");
tocTab[ir++] = new Array ("2.1.1.1.1", "Photo lateral", "trace_photo_lateral2.htm", "", "cicon35.gif", "cicon35.gif");
tocTab[ir++] = new Array ("2.1.1.1.2", "Photo frontal", "trace_photo_frontal2.htm", "", "cicon35.gif", "cicon35.gif");
tocTab[ir++] = new Array ("2.1.1.1.3", "Photo smiling", "trace_photo_smile2.htm", "", "cicon35.gif", "cicon35.gif");
tocTab[ir++] = new Array ("2.1.1.1.4", "Photo oblique", "trace_photo_oblique2.htm", "", "cicon35.gif", "cicon35.gif");
tocTab[ir++] = new Array ("2.1.1.2", "Intraoral Photos", "intraoralphotos.htm", "", "cicon1.gif", "cicon2.gif");
tocTab[ir++] = new Array ("2.1.1.2.1", "Intraoral lateral", "trace_io_lateral2.htm", "", "cicon35.gif", "cicon35.gif");
tocTab[ir++] = new Array ("2.1.1.2.2", "Intraoral frontal", "trace_io_frontal2.htm", "", "cicon35.gif", "cicon35.gif");
tocTab[ir++] = new Array ("2.1.1.2.3", "Intraoral maxilla", "trace_io_maxilla2.htm", "", "cicon35.gif", "cicon35.gif");
tocTab[ir++] = new Array ("2.1.1.2.4", "Intraoral mandible", "trace_io_mandible2.htm", "", "cicon35.gif", "cicon35.gif");
tocTab[ir++] = new Array ("2.1.1.3", "Xray Images", "xrayimages.htm", "", "cicon1.gif", "cicon2.gif");
tocTab[ir++] = new Array ("2.1.1.3.1", "Ceph lateral", "trace_ceph_lateral2.htm", "", "cicon35.gif", "cicon35.gif");
tocTab[ir++] = new Array ("2.1.1.3.2", "Ceph frontal", "trace_ceph_frontal2.htm", "", "cicon35.gif", "cicon35.gif");
tocTab[ir++] = new Array ("2.1.1.3.3", "Panoramic", "trace_pano2.htm", "", "cicon35.gif", "cicon35.gif");
tocTab[ir++] = new Array ("2.1.1.3.4", "Hand Xray", "trace_hand2.htm", "", "cicon35.gif", "cicon35.gif");
tocTab[ir++] = new Array ("2.1.1.3.5", "Tooth Xray", "trace_tooth2.htm", "", "cicon35.gif", "cicon35.gif");
tocTab[ir++] = new Array ("2.1.1.4", "Plaster Cast Photos", "plastercastphotos.htm", "", "cicon1.gif", "cicon2.gif");
tocTab[ir++] = new Array ("2.1.1.4.1", "Occlusion lateral", "trace_cast_lateral2.htm", "", "cicon35.gif", "cicon35.gif");
tocTab[ir++] = new Array ("2.1.1.4.2", "Occlusion frontal", "trace_cast_frontal2.htm", "", "cicon35.gif", "cicon35.gif");
tocTab[ir++] = new Array ("2.1.1.4.3", "Deciduous dentition", "trace_cast_dd2.htm", "", "cicon35.gif", "cicon35.gif");
tocTab[ir++] = new Array ("2.1.1.4.4", "Mixed dentition", "trace_cast_md2.htm", "", "cicon35.gif", "cicon35.gif");
tocTab[ir++] = new Array ("2.1.1.4.5", "Permanent dentition", "trace_cast_pd2.htm", "", "cicon35.gif", "cicon35.gif");
tocTab[ir++] = new Array ("2.1.1.5", "Userdefined Images", "userdefinedimages.htm", "", "cicon1.gif", "cicon2.gif");
tocTab[ir++] = new Array ("2.1.1.5.1", "User image types", "userimagetypes.htm", "", "cicon35.gif", "cicon35.gif");
tocTab[ir++] = new Array ("2.1.2", "Standard Analyses", "standardanalyseslibrary.htm", "", "cicon1.gif", "cicon2.gif");
tocTab[ir++] = new Array ("2.1.2.1", "Photo lateral ", "photolateral2.htm", "", "cicon17.gif", "cicon17.gif");
tocTab[ir++] = new Array ("2.1.2.2", "Photo frontal", "photofrontal2.htm", "", "cicon17.gif", "cicon17.gif");
tocTab[ir++] = new Array ("2.1.2.3", "Photo smiling", "photosmiling2.htm", "", "cicon17.gif", "cicon17.gif");
tocTab[ir++] = new Array ("2.1.2.4", "Ceph lateral", "cephlateral2.htm", "", "cicon17.gif", "cicon17.gif");
tocTab[ir++] = new Array ("2.1.2.5", "Ceph frontal", "cephfrontal2.htm", "", "cicon17.gif", "cicon17.gif");
tocTab[ir++] = new Array ("2.1.2.6", "Panoramic", "panoramic2.htm", "", "cicon17.gif", "cicon17.gif");
tocTab[ir++] = new Array ("2.1.2.7", "Hand Xray", "handxray2.htm", "", "cicon17.gif", "cicon17.gif");
tocTab[ir++] = new Array ("2.1.2.8", "Cast Deciduous dentition", "deciduousdentition2.htm", "", "cicon17.gif", "cicon17.gif");
tocTab[ir++] = new Array ("2.1.2.9", "Cast Mixed dentition", "mixeddentition2.htm", "", "cicon17.gif", "cicon17.gif");
tocTab[ir++] = new Array ("2.1.2.10", "Cast Permanent dentition", "permanentdentition2.htm", "", "cicon17.gif", "cicon17.gif");
tocTab[ir++] = new Array ("2.1.3", "Image Enhancement", "imageenhancement.htm", "", "cicon17.gif", "cicon17.gif");
tocTab[ir++] = new Array ("2.1.4", "Template Mode", "templatemode.htm", "", "cicon17.gif", "cicon17.gif");
tocTab[ir++] = new Array ("2.2", "Treatment Planning", "installation.htm", "", "cicon1.gif", "cicon2.gif");
tocTab[ir++] = new Array ("2.2.1", "Treatment Simulation", "treatmentsimulation_vts.htm", "", "cicon1.gif", "cicon2.gif");
tocTab[ir++] = new Array ("2.2.1.1", "Bony regions", "regions.htm", "", "cicon17.gif", "cicon17.gif");
tocTab[ir++] = new Array ("2.2.1.1.1", "Definition", "definitionofbonyregions.htm", "", "cicon35.gif", "cicon35.gif");
tocTab[ir++] = new Array ("2.2.1.1.1.1", "Region wizard", "regionwizard.htm", "", "cicon19.gif", "cicon19.gif");
tocTab[ir++] = new Array ("2.2.1.1.1.2", "New region", "newregion.htm", "", "cicon19.gif", "cicon19.gif");
tocTab[ir++] = new Array ("2.2.1.1.1.2.1", "Templates", "templates.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("2.2.1.1.1.2.2", "Freehand", "freehand.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("2.2.1.1.1.2.3", "Expand region", "expandregion.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("2.2.1.1.1.2.4", "Reduce region", "reduceregion.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("2.2.1.1.1.3", "Osteotomy wizards", "osteotomywizards.htm", "", "cicon19.gif", "cicon19.gif");
tocTab[ir++] = new Array ("2.2.1.1.1.3.1", "BSSO", "bsso.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("2.2.1.1.1.3.2", "LeFort I", "leforti.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("2.2.1.1.1.3.3", "BiMax", "bimax.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("2.2.1.1.1.3.4", "Genioplasty", "genioplasty.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("2.2.1.1.1.4", "Incision", "incision.htm", "", "cicon19.gif", "cicon19.gif");
tocTab[ir++] = new Array ("2.2.1.1.2", "Movement", "movement.htm", "", "cicon35.gif", "cicon35.gif");
tocTab[ir++] = new Array ("2.2.1.1.2.1", "Displacement", "displacement.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("2.2.1.1.2.2", "Rotation", "rotation.htm", "", "cicon9.gif", "cicon9.gif");
tocTab[ir++] = new Array ("2.2.1.2", "Soft tissue model", "definitionofsofttissuemode.htm", "", "cicon17.gif", "cicon17.gif");
tocTab[ir++] = new Array ("2.2.1.3", "Controls", "controls.htm", "", "cicon17.gif", "cicon17.gif");
tocTab[ir++] = new Array ("2.2.1.4", "Options", "options.htm", "", "cicon17.gif", "cicon17.gif");
tocTab[ir++] = new Array ("2.2.1.5", "Example", "example.htm", "", "cicon18.gif", "cicon18.gif");
tocTab[ir++] = new Array ("2.2.1.5.1", "Initial Photo lateral", "initialphoto.htm", "", "cicon35.gif", "cicon35.gif");
tocTab[ir++] = new Array ("2.2.1.5.2", "Initial Ceph Xray lateral", "initialcephxraylateral.htm", "", "cicon35.gif", "cicon35.gif");
tocTab[ir++] = new Array ("2.2.1.5.3", "Ceph tracing on photo", "cephtracingonphoto.htm", "", "cicon35.gif", "cicon35.gif");
tocTab[ir++] = new Array ("2.2.1.5.4", "BSSO wizard applied", "bssowizardapplied.htm", "", "cicon35.gif", "cicon35.gif");
tocTab[ir++] = new Array ("2.2.1.5.5", "Genioplasty applied", "genioplastyapplied.htm", "", "cicon35.gif", "cicon35.gif");
tocTab[ir++] = new Array ("2.2.1.5.6", "Planning on photo", "planningonphoto.htm", "", "cicon35.gif", "cicon35.gif");
tocTab[ir++] = new Array ("2.2.1.5.7", "Soft tissue prediction", "softtissueprediction.htm", "", "cicon35.gif", "cicon35.gif");
tocTab[ir++] = new Array ("2.2.1.5.8", "Final facial prediction", "finalfacialprediction.htm", "", "cicon35.gif", "cicon35.gif");
tocTab[ir++] = new Array ("2.2.1.5.9", "Post OP Photo", "postopphoto.htm", "", "cicon35.gif", "cicon35.gif");
tocTab[ir++] = new Array ("2.2.2", "Ricketts VTO", "treatmentobjective_vto.htm", "", "cicon1.gif", "cicon2.gif");
tocTab[ir++] = new Array ("2.2.3", "Juxtapose Findings", "treatmentanalysis_vta.htm", "", "cicon1.gif", "cicon2.gif");
tocTab[ir++] = new Array ("2.2.4", "Overlay Image/Findings", "overlayimagefindings.htm", "", "cicon1.gif", "cicon2.gif");
tocTab[ir++] = new Array ("2.3", "Case Documentation", "licenses.htm", "", "cicon1.gif", "cicon2.gif");
tocTab[ir++] = new Array ("2.3.1", "Standard Printout", "standardprintout.htm", "", "cicon35.gif", "cicon35.gif");
tocTab[ir++] = new Array ("2.3.2", "Individual Printforms", "individualprintforms.htm", "", "cicon35.gif", "cicon35.gif");
tocTab[ir++] = new Array ("2.3.3", "1:1 Printout", "11printout.htm", "", "cicon35.gif", "cicon35.gif");
tocTab[ir++] = new Array ("2.4", "Presentation", "registration.htm", "", "cicon1.gif", "cicon2.gif");
tocTab[ir++] = new Array ("2.4.1", "Albums", "albums.htm", "", "cicon35.gif", "cicon35.gif");
tocTab[ir++] = new Array ("2.4.2", "Full Screen", "fullscreen.htm", "", "cicon35.gif", "cicon35.gif");
tocTab[ir++] = new Array ("2.4.3", "Galleries", "galleries.htm", "", "cicon35.gif", "cicon35.gif");
tocTab[ir++] = new Array ("2.5", "Communication", "pricelist.htm", "", "cicon1.gif", "cicon2.gif");
tocTab[ir++] = new Array ("2.5.1", "Exchange", "exchange.htm", "", "cicon35.gif", "cicon35.gif");
tocTab[ir++] = new Array ("2.5.2", "Export", "export.htm", "", "cicon35.gif", "cicon35.gif");
tocTab[ir++] = new Array ("2.5.3", "Report", "report.htm", "", "cicon35.gif", "cicon35.gif");
tocTab[ir++] = new Array ("2.5.4", "Messages", "messages.htm", "", "cicon35.gif", "cicon35.gif");
tocTab[ir++] = new Array ("2.6", "Education &amp; Training", "contacts.htm", "", "cicon1.gif", "cicon2.gif");
isContent = true,
isIndex = false,
showNumbers = false,
textSizes = new Array(1, 1, 0.7, 0.7),
tocBehaviour = new Array(2,2),
tocScroll=false,
tocLinks = new Array(1,0);
var isIE = navigator.appName.toLowerCase().indexOf("explorer") > -1;
var mdi = (isIE) ? textSizes[1]:textSizes[3];
var sml = (isIE) ? textSizes[2]:textSizes[4];
var oldCurrentNumber = "", oldLastVisitNumber = "";
var toDisplay = new Array();
for (ir=0; ir<tocTab.length; ir++) {
toDisplay[ir] = tocTab[ir][0].split(".").length==1;
}
function reDisplay(currentNumber,tocChange,noLink,e) {
if (isIndex && (toc.location.href.substring(toc.location.href.lastIndexOf("/")+1,toc.location.href.length) != "navigator_kwindex.htm")) { isIndex=false; isContent=true; }
if (currentNumber == "navIndex") { isContent=false; }
if (currentNumber == "navContent") { isIndex=false; isContent=true; }
if (e) {
ctrlKeyDown = (isIE) ? e.ctrlKey : (e.modifiers==2);
if (tocChange && ctrlKeyDown) tocChange = 2;
}
var currentNumArray = currentNumber.split(".");
var currentLevel = currentNumArray.length-1;
var currentIndex = 0;
var scrollY=0, addScroll=tocScroll;
if (currentNumber == "") currentNumber = top.location.href.substring(top.location.href.lastIndexOf("?")+1,top.location.href.length);
for (i=0; i<tocTab.length; i++) {
if ((tocTab[i][0] == currentNumber) || (tocTab[i][2] == currentNumber && tocTab[i][2] != "")) {
currentIndex = i;
currentNumber = tocTab[i][0];
currentNumArray = currentNumber.split(".");
currentLevel = currentNumArray.length-1;
break;
}
}
if (currentIndex < tocTab.length-1) {
nextLevel = tocTab[currentIndex+1][0].split(".").length-1;
currentIsExpanded = nextLevel > currentLevel && toDisplay[currentIndex+1];
}
else currentIsExpanded = false;
theHref = (noLink) ? "" : tocTab[currentIndex][2];
theTarget = tocTab[currentIndex][3];
for (i=1; i<tocTab.length; i++) {
if (tocChange) {
thisNumber = tocTab[i][0];
thisNumArray = thisNumber.split(".");
thisLevel = thisNumArray.length-1;
isOnPath = true;
if (thisLevel > 0) {
for (j=0; j<thisLevel; j++) {
isOnPath = (j>currentLevel) ? false : isOnPath && (thisNumArray[j] == currentNumArray[j]);
}
}
toDisplay[i] = (tocChange == 1) ? isOnPath : (isOnPath || toDisplay[i]);
if (thisNumber.indexOf(currentNumber+".")==0 && thisLevel > currentLevel) {
if (currentIsExpanded) toDisplay[i] = false;
else toDisplay[i] = (thisLevel == currentLevel+1);
}
}
}
if (!isContent && !isIndex) {
toc.location.href = "navigator_kwindex.htm";
isIndex = true;
}
if (isContent) {
toc.document.write("<html>\n\r<head>\n\r   <LINK href=\"main.css\" type=text/css rel=stylesheet>  \n\r</head>\n\r<body bgcolor=\"#FFFFFF\">\n\r<table>   \n\r<tr>\n\r   <td class=subHed>&nbsp;Cephalometric Software<br>\n\r   <hr noshade size=\"1\"> \n\r   </td>\n\r</tr>\n\r</table>\n\r  <!-- Place holder for the TOC, do not delete the line below -->\n\r  ");}
for (i=0; i<tocTab.length; i++) {
if (toDisplay[i]) {
thisNumber = tocTab[i][0];
thisNumArray = thisNumber.split(".");
thisLevel = thisNumArray.length-1;
isCurrent = (i == currentIndex);
if (i < tocTab.length-1) {
nextLevel = tocTab[i+1][0].split(".").length-1;
img = (thisLevel >= nextLevel) ? tocTab[i][4] : ((toDisplay[i+1]) ? tocTab[i][5] : tocTab[i][4]);
}
else img = tocTab[i][4];
if (isContent) {
thisTextClass = ((thisNumber==currentNumber)?("hilight"):("heading"));
if (addScroll) scrollY+=((thisLevel<2)?mdi:sml)*25;
if (isCurrent) addScroll=false;
toc.document.write("<table border=0 cellspacing=0 cellpadding=2>");
toc.document.write("<tr><td width=" + ((thisLevel+1) * 14) + " align=right valign=top>");
toc.document.write("<a href=\"javaScript:history.go(0)\" onMouseDown=\"parent.reDisplay('" + thisNumber + "'," + tocBehaviour[0] + "," + tocLinks[0] + ",event)\">");
toc.document.write("<img src=\"" + img + "\" border=0></a>");
toc.document.write("</td><td align=left>");
toc.document.write("<a href=\"javaScript:history.go(0)\" onMouseDown=\"parent.reDisplay('" + thisNumber + "'," + tocBehaviour[1] + "," + tocLinks[1] + ",event)\">");
toc.document.write("<span class=\""  + thisTextClass + ((thisLevel>5) ? 6 : thisLevel+1) + "\">");
toc.document.write( ((showNumbers)?(thisNumber+" "):"") + tocTab[i][1]);
toc.document.write("</span></a>");
toc.document.writeln("</td></tr></table>");
} //isContent
}
}
if (!noLink) {
oldLastVisitNumber = oldCurrentNumber;
oldCurrentNumber = currentNumber;
}
if (isContent) {
toc.document.write("\n\r</body>\n\r</html>\n\r");
toc.document.close();
if (tocScroll) toc.scroll(0,scrollY);
}
if (theHref)
if (theTarget=="top") top.location.href = theHref;
else if (theTarget=="parent") parent.location.href = theHref;
else if (theTarget=="blank") open(theHref,"");
else content.location.href = theHref;
}

