
function pop_win(my_url,my_width,my_height, my_name){
	if(my_name=="")	my_name	="popWindow";
	my_params = 'WIDTH=' + my_width + ',HEIGHT=' + my_height + ',screenX=200,screenY=200,top=200,left=200,toolbar=0,scrollbars=1,location=0,statusbar=0,menubar=0,resizable=1';
	popWindow = window.open(my_url,my_name,my_params); // open window and bring to front
	popWindow.window.focus();
}

function pop_vid(my_vid_id,my_width,my_height){
	my_vid_url='tools/video_view.dwp?vid_id=' + my_vid_id;
	my_params = 'WIDTH=' + my_width + ',HEIGHT=' + my_height + ',screenX=20,screenY=20,top=20,left=20,toolbar=0,scrollbars=1,location=0,statusbar=0,menubar=0,resizable=1';
	popWindow = window.open(my_vid_url,'Vidwin',my_params); // open window and bring to front
	popWindow.window.focus();
}


function SM_div_toggle(my_action,component_id){

	if(my_action=='open'){
		switch_on = "trigger_open_"+component_id;
		switch_off = "trigger_closed_"+component_id;
		
		controls_on = "trigger_open_"+component_id;
		controls_off = "trigger_closed_"+component_id;
	}else{
		switch_on = "trigger_closed_"+component_id;
		switch_off = "trigger_open_"+component_id;
		
		controls_on = "trigger_closed_"+component_id;
		controls_off = "trigger_open_"+component_id;
	}
    
	document.getElementById(switch_off).style.display = "none" ;
	document.getElementById(controls_off).style.display = "none" ;
	
	document.getElementById(switch_on).style.display = "block" ;
	document.getElementById(controls_on).style.display = "block" ;
		
}

