var popWindow;

// creates a simple popup window of the given size
function PopupWindow(url, width, height, scrollbar)
{
	popWindow = window.open(url,'name','height='+height+',width='+width+',scrollbars='+scrollbar);
	
	if (window.focus)
	{
		popWindow.focus();
	}
}

// go to the site littletrickygames with the platform in mind
function GotoLittleTrickyGames( inWindow )
{
	var OS = navigator.platform.toLowerCase();
	
	if (OS.indexOf("mac") != -1)
	{
		if (inWindow == "1")
		{
			window.open('http://www.littletrickygames.com/menu/mac-games', '_blank');
		}
		else {
			this.location.href = "http://www.littletrickygames.com/menu/mac-games";
		}
	}
	else
	{
		if (inWindow == "1")
		{
			window.open('http://www.littletrickygames.com', '_blank');
		}
		else {
			this.location.href = "http://www.littletrickygames.com";
		}
	}
}

// go to the app store with the platform in mind
function GotoAppStore( appID, inWindow )
{
	if (inWindow == "1")
	{
		window.open('http://itunes.apple.com/WebObjects/MZStore.woa/wa/viewSoftware?id=' + appID, '_blank');
	}
	else {
		this.location.href = "http://itunes.apple.com/WebObjects/MZStore.woa/wa/viewSoftware?id=" + appID;
	}
}

