//	File: tframe.js

function set_tbar_state() {
// Set the image in the tbar (frames or noframes)
	if (parent.frames.length > 1)
		document.tbar.src = "../common/noframes.gif"
	else
		document.tbar.src = "../common/frames.gif"
}

function switch_state() {
// Switch from full screen to within the frame
//	"mainFrame" of the parent frameset (must be "index.html"
	if (parent.frames.length > 1) {
	// We have frames, but want to turn them off
		parent.location.href = document.URL
	}
	else {
	// We don't have frames but want to turn them on
		ns = document.URL.lastIndexOf("/")
		nb = document.URL.lastIndexOf("\\")
		if (nb > ns) ns = nb
		window.location.href = "index.html?" +
			document.URL.substring(ns+1,document.URL.length)
	}
}
// End tframe.js

