<!-- 
/* BROWSEROBJ.JS
 * ===========================================
 * Author: Gregory Segall
 * Date: 5 Jun 03
 */
 

/* objBrowser
 * =====================
 * Constructor for objBrowser with properties:
 * 1> platform
 *    .mac, .win, .otherPlatform
 * 2> browser type (only 5th gen browsers have getElementById method)
 *    .ns, .ie, .dom, .otherBrowser
 * 3> browser type add version
 *    .ns2, .ns3, .ns3up, .ns4, .ns45, .ns47, .ns4up, .ns6, .ie3, .ie4, .ie4up, .ie5up
 * 4> javascript version
 *    .js10, .js11, .js12, .js13up
 * 5> other categories bool
 *    .dhtml, .css1, .frames
 * 6> other categories int (avail screen space, browser version)
 *    .width, .height, .verInt
 * 7> other categories float
 *    .verFloat
 *
 * Return value:
 * this
 *
 * Parameters:
 * none
 */
 
 function objBrowser() {
   this.verFloat = parseFloat(navigator.appVersion);
   this.verInt = parseInt(navigator.appVersion);
   // platform
   this.mac = (navigator.platform == "MacPPC");
   this.win = ((navigator.platform == "Win32") || (navigator.platform.indexOf("16bit")!=-1))?1:0;
   this.otherPlatform = (!this.mac && !this.win);
   this.dom = (document.getElementById)?1:0;
   // netscape
   this.ns = (navigator.appName.indexOf("Netscape")!=-1)?1:0;
   this.ns2 = (this.ns && this.verInt <= 2);
   this.ns3 = (this.ns && this.verInt <= 3);
   this.ns3up = (this.ns && this.verFloat >= 3 && this.verFloat < 5);
   this.ns4 = (this.ns && this.verFloat >= 4.05 && this.verFloat < 5);
   this.ns45 = (this.ns && this.verFloat >= 4.5 && this.verFloat < 4.7);
   this.ns47 = (this.ns && this.verFloat >= 4.7 && this.verFloat < 5);
   this.ns4up = (this.ns && this.verFloat >= 4.05);
   this.ns6 = (this.ns && this.dom);
   // internet explorer
   this.ie = (document.all)?1:0;
   this.ie3 = (this.ie && this.verInt < 4);
   this.ie4 = (this.ie && !this.dom)?1:0;
   this.ie4up = (this.ie && this.verFloat >= 4);
   this.ie5up = (this.ie && this.dom);
   this.ie6 = ((this.ie && this.dom) && (navigator.userAgent.indexOf("MSIE 6")!=-1))?1:0;
   // other browser
   this.otherBrowser = !(this.ns || this.ie);
   // browser avail width/height (ns)
   this.nsWidth = window.innerWidth;
   this.nsHeight = window.innerHeight;
   // js versions
   this.js10 = (this.ns2 || this.ie3);
   this.js11 = (this.ns3);
   this.js12 = ((this.ns4 && (this.verFloat <= 4.05)) || this.ie4);
   this.js13 = ((this.ns4 && (this.verFloat > 4.05)) || this.ns4up || this.ie4up);
   this.dhtml = ((this.ns4 && (this.verFloat > 4.05)) || this.ns4up || this.ie4up || this.dom);
   this.css1 = (this.ns4up || this.ie4up || this.dom);
   this.frames = (this.ns || this.ie3 || this.ie4up);
   
   if (this.ns4up) {
	 window.onresize = fncHandleResize;
   }
   return this;
 }
 
 // instantiate objBrowser object
 var objClient = new objBrowser();

/* fncHandleResize
 * =====================
 * Function for fixing netscape resize bug:
 *
 * Return value:
 * none
 *
 * Parameters:
 * none
 */
 
 function fncHandleResize() {
   if ((window.innerWidth != objClient.width) || (window.innerHeight != objClient.height))
     document.location.reload();
 }
 
 // end hide -->