function windowPositionCenter(w,h) {
	window.moveTo((screen.width-w)/2,(screen.height-h)/2);
}
function windowResize( w, h, bCenter) {
	window.resizeTo(w,h);
	if ( bCenter )
		windowPositionCenter(w,h);
}
function windowResizeBy(w, h, bCenter) {
	window.resizeBy(w - document.body.clientWidth,h - document.body.clientHeight);
	if ( bCenter )
		windowPositionCenter(w,h);
}
function windowResizeEx(w,h, bCenter) {
	windowResize(w+12, h+31, bCenter);
}
function windowAutoResize(bCenter) {
	windowResizeBy(document.body.scrollWidth,document.body.scrollHeight,bCenter);
}
function windowAutoResize2(bCenter) {
	windowResizeEx(document.body.scrollWidth-2,document.body.scrollHeight-2,bCenter);
}
function winAutoResize(bCenter) {
	windowResizeBy(document.body.scrollWidth, document.body.scrollHeight, bCenter);
}
function windowGetSize() {
	alert(document.body.scrollWidth+"/"+document.body.scrollHeight);
}
function windowAutoGetSize() {
	if ( bWinGetSize )
		windowGetSize();
}
bWinGetSize = false;
window.onload = windowAutoGetSize;