/* -------------------------------------------------------------------------- */
/*                             JAVASCRIPT VISION                              */
/*                         Window Management Methods                          */
/* -------------------------------------------------------------------------- */
/*                     Single Window Management Methods                       */
/* -------------------------------------------------------------------------- */

function JSV_popWindow(winHandle, winName, winURL, winAttributes, winReplace) {
	var winClosed = false;
	if (winHandle == null) winClosed = true;
	else if (winHandle.closed) winClosed = true;

	if (!winClosed) {
		if (winReplace)
			winHandle.location.replace( winURL );
		else
			winHandle.location.href = winURL;
	}
	else {
		winHandle = window.open(winURL, winName, winAttributes);
	}
	return winHandle;
}
