// Support Script (633)
DurationToSeconds = new Array(3);
DurationToSeconds["Slow"]   = 6;
DurationToSeconds["Medium"] = 3;
DurationToSeconds["Fast"]   = 1;

// Support Script (634)
// Copyright (c) 1998 by Elemental Software, Inc. - ALL RIGHTS RESERVED.
// Get browser info. This only gets the client size at this time
//
function browserInfo()
{
	this.width  = 0;  // default return value - indicates undetermined value.
	this.height = 0;

	if (document.body && document.body.clientWidth) // IE
	{
		this.width  = document.body.clientWidth;
		this.height = document.body.clientHeight;
	}
	else if (window.innerWidth)
	{
		this.width  = window.innerWidth;
		this.height = window.innerHeight;
	}
}

// Determine the browser type and check if version 4 browser
// is used.

   IE4 = (document.all) ? 1 : 0;
   NC4 = (document.layers) ? 1 : 0;
   ver4 = (IE4 || NC4) ? 1 : 0;


// Support Script (779)
// Copyright (c) 1998 by Elemental Software, Inc. - ALL RIGHTS RESERVED.
//
// This class finds the named object in either 4.0 DOM and 
// gathers information about it.
//
function objectInfo(objName)
{
	this.fullName = ""; // if this does not get filled the object could not be found.

	if (objName.length == 0) return;

	this.hide = objectInfoHide;
	this.show = objectInfoShow;
	this.setLeft = objectInfoSetLeft;
	this.setTop  = objectInfoSetTop;
	this.getPosition  = objectInfoGetPosition;
	this.isValid      = objectInfoIsValid;
	this.isValidIE    = objectInfoIsValidIE;
	this.getZindex    = objectInfoGetZindex;
	this.setZindex    = objectInfoSetZindex;
	this.getDimension = objectInfoGetDimension;
	this.setDimension = objectInfoSetDimension;
 this.shiftTo      = objectInfoShiftTo;

	// find the named object in the DOM and then get the properties

	if (document.all) // IE
	{
		while (true)
		{
			if (eval("document.all.DBStyle" + objName))
			{
				if (eval("document.all.DBStyle" + objName + ".offsetWidth"))
				{
					this.fullName = "document.all.DBStyle" + objName;
					this.tagName  = this.fullName;
				}
			}
			else if (eval("document.all." + objName))
			{
				if (eval("document.all." + objName + ".offsetWidth"))
				{
					// Text in DIV tags are caught here
					this.fullName = "document.all." + objName;
					this.tagName  = this.fullName;
				}
				else if (eval("document.all." + objName + "." + objName) != null)
				{
					// Other tags are caught here.
					if (eval("document.all." + objName + "[1].tagName")  != "DIV")
					{
						this.fullName = "document.all." + objName + "[0]";
						this.tagName  = "document.all." + objName + "[1]";
					}
				}
			}

			// strip underscores out of input and try one more time
			if (this.fullName.length > 0) break;
			objName2 = objName.replace(/_/, "");
			if (objName2 == objName) break;
			objName = objName2;
		}

		
		if (this.fullName.length > 0)
		{
			this.styleKey = '.style'; // used to access style info
			this.width  = eval(this.fullName + ".offsetWidth");
			this.height = eval(this.fullName + ".offsetHeight");
		}
	}
	else  // NC
	{
		if (document.layers)
		{
			sectionNumber = 0;
			while (true)
			{
				sectionName = "LyrSection" + sectionNumber.toString();
				if (eval("document.layers." + sectionName) == null) break;  // can't find object in DOM

				// see if this is an object in the DOM
				if (eval("document.layers." + sectionName + ".document"))
				{
					while (true)
					{
						if (eval("document.layers." + sectionName + ".document.layers.LyrDBStyle" + objName))
						{
							this.fullName = "document.layers." + sectionName + ".document.layers.LyrDBStyle" + objName;
							this.tagName  = "document.layers." + sectionName + ".document." + objName; 
							break;
						}
						else if (eval("document.layers." + sectionName + ".document.layers.Lyr" + objName))
						{
							this.fullName = "document.layers." + sectionName + ".document.layers.Lyr" + objName;
							this.tagName  = "document.layers." + sectionName + ".document." + objName; 
							break;
						}
						else if (eval("document.layers." + sectionName + ".document.layers." + objName))
						{
							this.fullName = "document.layers." + sectionName + ".document.layers." + objName;
							this.tagName  = "document.layers." + sectionName + ".document." + objName; 
							break;
						}

						// strip underscores out of input and try one more time
						if (this.fullName.length > 0) break;
						objName2 = objName.replace(/_/, "");
						if (objName2 == objName) break;
						objName = objName2;
					}

				} else alert("objectInfo: " + "document.layers." + sectionName + ".document" + " is not an object");

				sectionNumber++;
			} // end while (looping over all SectionN relative positioning layers)

			if (this.fullName.length > 0 && "undefined" != typeof(eval(this.fullName + ".pageX")))
			{
				this.styleKey = '';

				if (eval(this.fullName + ".dbWidth"))
				{
					// we have previously set the values - get them from here, since if we changed
					// the clipping region the size will be wrong (it will be clipping size - not native size).
					this.width  = eval(this.fullName + ".dbWidth");
					this.height = eval(this.fullName + ".dbHeight");
				}
				else
				{
					// get the clipping size and save it off since we haven't yet clipped this guy.
					this.width  = eval(this.fullName + ".clip.width");
					this.height = eval(this.fullName + ".clip.height");
					eval(this.fullName + ".dbWidth  = this.width");
					eval(this.fullName + ".dbHeight = this.height");
				}
			}
			else
			{
				this.fullName = "";
				this.tagName  = "";
			}
		}  // end if (document.layers  e.g. NC)
	}
	this.object = null;
	if (this.fullName.length > 0)
		this.object = eval(this.fullName);
}

function objectInfoHide()
{	
	if (this.fullName.length > 0)
		eval(this.fullName + this.styleKey + ".visibility = 'hidden';");
}

function objectInfoShow()
{
	if (this.fullName.length > 0)
		eval(this.fullName + this.styleKey + ".visibility = 'visible';");
}

function objectInfoSetLeft(left)
{
	if (this.fullName.length > 0)
		eval(this.fullName + this.styleKey + ".left = left");
}

function objectInfoSetTop(top)
{
	if (this.fullName.length > 0)
		eval(this.fullName + this.styleKey + ".top = top");
}

function objectInfoGetPosition()
{
	ret = null;
	if (this.fullName.length > 0)
	{
		if ("undefined" != typeof(eval(this.fullName + ".offsetLeft")))
		{
			ret = new Object;
			ret.left   = eval(this.fullName + ".offsetLeft");
			ret.top    = eval(this.fullName + ".offsetTop");
		}
		else if ("undefined" != typeof(eval(this.fullName + ".pageX")))
		{
			ret = new Object;
			ret.left = eval(this.fullName + ".pageX");
			ret.top  = eval(this.fullName + ".pageY");
		}
	}
	return ret;
}

function objectInfoIsValid()
{
	return (this.fullName.length > 0 && this.object);
}

function objectInfoIsValidIE()
{
	return (this.fullName.length > 0 && this.object && document.all);
}


function objectInfoGetZindex()
{
	  if (this.fullName.length > 0)
  	{
	   ret = eval(this.fullName + this.styleKey + ".zIndex");
	   return (ret);
  	}
}

function objectInfoSetZindex(ind)
{
  if (this.fullName.length > 0 )
  {
    eval(this.fullName + this.styleKey + ".zIndex = ind");
  }
}

function objectInfoGetDimension()
{

   ret = null;
   ret = new Object;
   if (document.all) {  // IE
      ret.width = eval(this.fullName + ".offsetWidth");
      ret.height = eval(this.fullName + ".offsetHeight");
   }
   else {  // NC
      if (eval(this.fullName + ".dbWidth")) {
         ret.width  = eval(this.fullName + ".dbWidth");
         ret.height = eval(this.fullName + ".dbHeight");
      }
      else {
         ret.width = eval(this.fullName + ".clip.width");
         ret.height = eval(this.fullName + ".clip.height");
      }
   }
    
   return (ret);
}       

function objectInfoSetDimension(w, h)
{
   if (document.all) { // IE
     eval(this.fullName + this.styleKey + ".width = w");
     eval(this.fullName + this.styleKey + ".height = h");
   }
   else { // NC
     if (eval(this.fullName + ".clip.width")) {
        eval(this.fullName + ".clip.width = w");
        eval(this.fullName + ".clip.height = h");
     }
     eval(this.fullName + ".dbWidth = w");
     eval(this.fullName + ".dbHeight = h");
   }
   this.width = w;
   this.height = h;
}

function objectInfoShiftTo(x, y)
{
   if (document.all) { // IE
      eval(this.fullName + this.styleKey + ".left = x");
      eval(this.fullName + this.styleKey + ".top  = y");
   }
   else { // NC
      eval(this.fullName + ".moveTo(x,y)");
   }
}
// Support Script (636)
// Copyright (c) 1998 by Elemental Software, Inc. - ALL RIGHTS RESERVED.
//
// Compute a position that is currently off the visible screen.
//
function offScreenPos(ObjInfo, BrowserInfo, Direction)
{
	margin = 25;  // this is extra space off the screen to place the object

	pos = ObjInfo.getPosition();

	this.left = pos.left;
	if (Direction.toUpperCase().indexOf("LEFT") >= 0)
		this.left = -ObjInfo.width -margin;
	else if (Direction.toUpperCase().indexOf("RIGHT") >= 0)
		this.left = BrowserInfo.width + margin;
		
	this.top  = pos.top;
	if (Direction.toUpperCase().indexOf("TOP") >= 0)
		this.top = -ObjInfo.height -margin;
	else if (Direction.toUpperCase().indexOf("BOTTOM") >= 0)
		this.top = BrowserInfo.height + margin;
}

// Support Script (637)
// Copyright (c) 1998 by Elemental Software, Inc. - ALL RIGHTS RESERVED.
//
// This class slides a browser object to a new position over a given time.
// The object to slide is identified via a objectInfo object.
// 
function slideTo(objInfo, xFinal, yFinal, duration)
{
	// add properties to the input named object so that the iterative function
	// slideToExecute can iterate on the object and move it across the screen
	
	// Length of each incremental move of the object in milliseconds.
	// larger values make for jerkier motion, smaller values use more CPU cycles
	var incPeriod = 20; // milliseconds

	var slName = objInfo.fullName;
	if (slName.length > 0) // make sure we found the named object in DOM
	{
		// compute new Y value due to possible divider element on page
		// this is an IE only fix - NC still exhibits some weird behavour.
		yFinal = parseInt(yFinal);
		if (objInfo.object.parentElement != null)
			if (objInfo.object.parentElement.offsetTop != null) 
				yFinal -= objInfo.object.parentElement.offsetTop;

		// add properties to the DOM object so they are available later
		pos = objInfo.getPosition();
		if (pos)
		{
			eval(slName + ".slStyleKey = objInfo.styleKey");
			eval(slName + ".xInit = " + "pos.left");
			eval(slName + ".yInit = " + "pos.top");
			eval(slName + ".slName = slName"); // the qualified name of the object in the DOM
			eval(slName + ".xFinal = xFinal"); // final position
			eval(slName + ".yFinal = yFinal");
			eval(slName + ".iStep = 0");       // counter
			eval(slName + ".incPeriod = incPeriod");  // period of each increment
			eval(slName + ".nSteps = (duration * 1000) / " + slName + ".incPeriod"); // number of steps
			eval(slName + ".slideToExecute = slideToExecute");

			if (duration > 0)
				eval(slName + ".slideToExecute()");
			else // duration of 0 implies just move it.
			{
				objInfo.setLeft(xFinal);
				objInfo.setTop (yFinal);
			}
		} else alert("slideTo: could not get position of element");
	}
}

function slideToExecute()
{
	// increment the counter and compute the next intermediate position.
	// set the new position using DOM specific code generated above

	this.iStep++;
	xNow = this.xInit + (((this.xFinal - this.xInit) * this.iStep) / this.nSteps);
	eval(this.slName + this.slStyleKey + ".left = Math.round(xNow).toString()");

	yNow = this.yInit + (((this.yFinal - this.yInit) * this.iStep) / this.nSteps);
	eval(this.slName + this.slStyleKey + ".top = Math.round(yNow).toString()");

	if (this.iStep < this.nSteps) // are we done yet?
	{
		setTimeout(this.slName + ".slideToExecute()", this.incPeriod);
	}
	else // we are done - force the final position.
	{
		eval(this.slName + this.slStyleKey + ".left = this.xFinal.toString()");
		eval(this.slName + this.slStyleKey + ".top  = this.yFinal.toString()");
	}
}

function document_onLoad() {
Text3_Info = new objectInfo("Text3");
dbBrowser = new browserInfo();

if (Text3_Info.fullName.length > 0 && dbBrowser.width > 0)
{
	Text3_Info.hide();

	Text3_pos = Text3_Info.getPosition();
	if (Text3_pos)
	{
		Text3_offscreenPos = new offScreenPos(Text3_Info, dbBrowser, "Right");
		Text3_Info.setLeft( Text3_offscreenPos.left);
		Text3_Info.setTop(  Text3_offscreenPos.top);

		Text3_Info.show();
		Text3duration = DurationToSeconds["Fast"];
		setTimeout('slideTo(Text3_Info,Text3_pos.left,Text3_pos.top,Text3duration);', 1);
	}
}
 }

