﻿
function openwindow1()
{
	window.open("http://gage.he.net/~woodvill/z_views/print/print_village.html","mywindow","menubar=0,resizable=1,width=700,height=435");
}
function openwindow2()
{
	window.open("http://gage.he.net/~woodvill/z_views/print/print_local.html","mywindow","menubar=0,resizable=1,width=700,height=435");
}
function openwindow3()
{
	window.open("http://gage.he.net/~woodvill/z_views/print/print_region.html","mywindow","menubar=0,resizable=1,width=700,height=435");
}


/*****************************************************************************
* Gallery popup - function for showing popup window in the gallery 
*****************************************************************************/


function popitup(url) {
	newwindow=window.open(url,'name','height=593, width=730,resizable,scrollbars=no,status=0');
	if (window.focus) {newwindow.focus()}
	return false;
}

function fitPic() {
	if (window.innerWidth){
		curWindowWidth = window.innerWidth;
		curWindowHeight = window.innerHeight;
	}else{
		curWindowWidth = document.body.clientWidth;
		curWindowHeight = document.body.clientHeight;
	}
	
	frameHeight = 140;
	frameWidth = 50;
	
	finalWidth = document.images[1].width - curWindowWidth + frameWidth;
	finalHeight = document.images[1].height - curWindowHeight + frameHeight;
	
	window.resizeBy(finalWidth, finalHeight);
};

function popupFloor(building, id) {
	newwindow=window.open('http://woodinvillevillage.com/popupFloor?bldg=' + building + '&id=' + id,'popup','height=610, width=750,resizable,scrollbars=no,status=0');
	if (window.focus) {newwindow.focus()}
	
	return true;
}


