﻿function GlobalsClass(){
	this.debug = true;
}
GlobalsClass.prototype.alert = function(aText){
	if (!this.debug) return;
	alert(aText);
}
GlobalsClass.prototype.disableSubmit = function disableSubmit(e){
	var characterCode;

	if(e && e.which){ 
		e = e;
		characterCode = e.which;
	}else{
		e = window.event;
		characterCode = e.keyCode;
	}
	if(characterCode == 13){
		e.cancelBubble = true;
		return false;
	}
	return true;
}
var Globals = new GlobalsClass();

//window.onload = activateActiveX;

function LoadDone(aId){
	if (!aId) aId = "BackLoading";
	document.getElementById(aId).style.display="none";
	
}

function OpenPopup(URI, Width, Height) {
   var Settings = "scrollbars=yes,resizable=yes,";
   Settings = Settings + "width=" + Width;
   Settings = Settings + ",height=" + Height; 
   theNewWin = window.open(URI, 'popup', Settings);
   theNewWin.focus();
}

function OpenPopupGallery(URI) {
   var lH = screen.height - 60;
   var Settings = "scrollbars=yes,resizable=yes,";
   Settings = Settings + "width=770";
   Settings = Settings + ",height=" + lH; 
   theNewWin = window.open(URI, 'popup', Settings);
   theNewWin.focus();
}

function activateActiveX() 
{ 
  var activeXObjTypes = new Array( "applet", "embed", "object" ); 
  for ( var i = 0; i < activeXObjTypes.length; i++ ) 
  { 
    var xObj = document.getElementsByTagName( activeXObjTypes[i] ); 
    for( var j = 0; j < xObj.length; j++ ) 
    { 
      xObj[j].outerHTML = xObj[j].outerHTML; 
    } 
  } 
} 



