# ****************************************************************************
# Surgeweb javascript - Various things that should not be in the final product
# Note: sw.js is the primary surgeweb javascript code
# ----------------------------------------------------------------------------
#  - Stuff for demoing
#  - Experimental stuff that I'm not ready to delete yet
# ****************************************************************************


function beta_showpane()
{
	new_win = open_popup('cmd=show&page=beta_info.htm');
	if (!new_win) return;
	document.set_sid=set_sid;
	new_win.focus();
}
function beta_showchanges()
{
	new_win = open_popup('cmd=show&page=beta_history.htm');
	if (!new_win) return;
	document.set_sid=set_sid;
	new_win.focus();
}


function beta_hook_msg_show(){
	var oldMsgfn=M;
	M=function(item){
		alert("my custom message submission function about to call the orig function :-)");
		oldMsgfn(item);
	}
}
function beta_hook_msg_show_cb(){
	var oldMsgfn=M_cb;
	M_cb=function(txt){
		if(http.readyState == 4)
			alert("my custom data callback hook eg allows client side data manipulation, before message passed to the orig function :-)");
		oldMsgfn(txt);
	}
}

