/**************
 *	browser.js
 **************/
 
function Browser(uAgent,platform,version) {
	this.uAgent = uAgent;
	this.platform = platform;
	this.version = version;
	
	this.isIE = this.uAgent.indexOf('MSIE') > -1 ? true : false;
	
	this.chrome = {top:0,bottom:0,left:0,right:0,height:0,width:0};

//	if(this.uAgent.indexOf('MSIE') > -1) { // MSIE
	if(this.isIE) {
		this.chrome.top = 24;
		// this.chrome.bottom = 5; // changes to IE6 SP 2 and above mean the status bar is always on  
		this.chrome.bottom = 25;
		this.chrome.left = 5;
		this.chrome.right = 5;
		this.chrome.height = this.chrome.top + this.chrome.bottom;
		this.chrome.width = this.chrome.left + this.chrome.right;
	}
//	else if (this.uAgent.indexOf('Mozilla') > -1) {
	else {
		this.chrome.top = 24;
		this.chrome.bottom = 25;
		this.chrome.left = 3;
		this.chrome.right = 3;
		this.chrome.height = this.chrome.top + this.chrome.bottom;
		this.chrome.width = this.chrome.left + this.chrome.right;
	}

}

function get_browser() {
	var output = new String();
	for(var i in navigator) {
		output += i + ': ' + navigator[i] + '\n';
	}
	return new Browser(navigator.userAgent,navigator.platform,navigator.appVersion);
}

var oBrowser = get_browser();
