var scrollbar;
var win = null; 

function newWindow(mypage,myname,w,h,features) { 


	var tempvar = navigator.platform.toUpperCase();
	var loc = "unknown.html";
	
	if (tempvar.indexOf("WIN") !=-1) {w = 540; h= 360;}
	else if (tempvar.indexOf("MAC") !=-1) { w = 545; h= 365; };
	
	

	var winl = (screen.width-w)/2; var wint = (screen.height-h)/2; 
	if (winl < 0) winl = 0; 
	if (wint < 0) wint = 0; 
	var settings = 'height=' + h + ','; 
	settings += 'width=' + w + ','; 
	settings += 'top=' + wint + ','; 
	settings += 'left=' + winl + ','; 
	settings += features; 
	win = window.open(mypage,myname,settings); 
	win.window.focus();
}

function PopWindow()
{
window.open('','popup1','width=350,height=470,menubar=no,scrollbars=no,toolbar=no,location=no,directories=no,resizable=no,top=0,left=0');
}
function PopWindow2()
{
window.open('shopbistropopup.htm','popup2','width=337,height=198,menubar=no,scrollbars=no,toolbar=no,location=no,directories=no,resizable=no,top=365,left=88');
}
function PopWindow3()
{
window.open('shopbistropopupeng.htm','popup3','width=337,height=198,menubar=no,scrollbars=no,toolbar=no,location=no,directories=no,resizable=no,top=365,left=88');
}
function PopWindow4()
{
window.open('greetings','popup4','width=955,height=600,menubar=no,scrollbars=no,toolbar=no,location=no,directories=no,resizable=no,top=20,left=88');
}

function scrollbarPressed (o, c, e) {
	o.className += "-Pressed";
};

function scrollbarReleased (o, c, e) {
	o.className = o.className.replace("-Pressed", "");
};

window.onload = function () {
	//PopWindow4();
	var content = document.getElementById("Example-3-Content");
	var scrollb = document.getElementById("Example-3-Scrollbar");

	scrollbar = new Scrolling.Scrollbar (
		scrollb,
		new Scrolling.Scroller (content, 400, 180),
		new Scrolling.ScrollTween()
	);
	
	scrollbar.onMouseDown = scrollbarPressed;
	scrollbar.onMouseUp   = scrollbarReleased;
	

	
};

function MM_reloadPage(init) {  //reloads the window if Nav4 resized
  if (init==true) with (navigator) {if ((appName=="Netscape")&&(parseInt(appVersion)==4)) {
    document.MM_pgW=innerWidth; document.MM_pgH=innerHeight; onresize=MM_reloadPage; }}
  else if (innerWidth!=document.MM_pgW || innerHeight!=document.MM_pgH) location.reload();
}
MM_reloadPage(true);