function ImgShw(ID, width, height, alt)
{
    var scroll = "no";
    var top=0, left=0;
    if(width > screen.width-10 || height > screen.height-28) scroll = "yes";
    if(height < screen.height-28) top = Math.floor((screen.height - height)/2-14);
    if(width < screen.width-10) left = Math.floor((screen.width - width)/2-5);
    width = Math.min(width, screen.width-10);
    height = Math.min(height, screen.height-28);
    var wnd = window.open("","","scrollbars="+scroll+",resizable=yes,width="+width+",height="+height+",left="+left+",top="+top);
    wnd.document.write("<html><head>\n");
    wnd.document.write("<"+"script language='JavaScript'>\n");
    wnd.document.write("<!--\n");
    wnd.document.write("function KeyPress()\n");
    wnd.document.write("{\n");
    wnd.document.write("     if(window.event.keyCode == 27)\n");
    wnd.document.write("          window.close();\n");
    wnd.document.write("}\n");
    wnd.document.write("//-->\n");
    wnd.document.write("</"+"script>\n");
    wnd.document.write("<title>"+(alt == ""? "Картинка":alt)+"</title></head>\n");
    wnd.document.write("<body topmargin=\"0\" leftmargin=\"0\" marginwidth=\"0\" marginheight=\"0\" onKeyPress=\"KeyPress()\">\n");
    wnd.document.write("<img src=\""+ID+"\" border=\"0\" alt=\""+alt+"\">");
    wnd.document.write("</body>");
    wnd.document.write("</html>");
    wnd.document.close();
}

function f_foo(z) {
      if (z == 1) {
        			
        	document.getElementById('u1').style.display='none';
        	document.getElementById('u2').style.display='block';
      }
        		
		if (z == 2) {
					
        	document.getElementById('u1').style.display='block';
        	document.getElementById('u2').style.display='none';
        		    
        		    
        }
        		
        		
    }

			
var t = 0;
var v = 0;
var c_name = '';
var n = '';
obj_astra =  new Fx.Slide('astra', {duration: 250});
obj_astra.hide();
obj_astra_s =  new Fx.Slide('astra_s', {duration: 250});
obj_astra_s.hide();
obj_corsa =  new Fx.Slide('corsa', {duration: 250});
obj_corsa.hide();
obj_vectra =  new Fx.Slide('vectra', {duration: 250});
obj_vectra.hide();
obj_zafira =  new Fx.Slide('zafira', {duration: 250});
obj_zafira.hide();
obj_meriva =  new Fx.Slide('meriva', {duration: 250});
obj_meriva.hide();
obj_signum =  new Fx.Slide('signum', {duration: 250});
obj_signum.hide();
obj_antara =  new Fx.Slide('antara', {duration: 250});
obj_antara.hide();
obj_cruze =  new Fx.Slide('cruze', {duration: 250});
obj_cruze.hide();
obj_aveo =  new Fx.Slide('aveo', {duration: 250});
obj_aveo.hide();
obj_spark =  new Fx.Slide('spark', {duration: 250});
obj_spark.hide();
obj_lanos =  new Fx.Slide('lanos', {duration: 250});
obj_lanos.hide();
obj_lacetti =  new Fx.Slide('lacetti', {duration: 250});
obj_lacetti.hide();
obj_rezzo =  new Fx.Slide('rezzo', {duration: 250});
obj_rezzo.hide();
obj_epica =  new Fx.Slide('epica', {duration: 250});
obj_epica.hide();
obj_captiva =  new Fx.Slide('captiva', {duration: 250});
obj_captiva.hide();
obj_tahoe =  new Fx.Slide('tahoe', {duration: 250});
obj_tahoe.hide();
obj_trailblazer =  new Fx.Slide('trailblazer', {duration: 250});
obj_trailblazer.hide();
obj_cad_ctc =  new Fx.Slide('cad_ctc', {duration: 250});
obj_cad_ctc.hide();
obj_cad_sts =  new Fx.Slide('cad_sts', {duration: 250});
obj_cad_sts.hide();
obj_cad_bls =  new Fx.Slide('cad_bls', {duration: 250});
obj_cad_bls.hide();
obj_cad_srx =  new Fx.Slide('cad_srx', {duration: 250});
obj_cad_srx.hide();

obj_cad_escalade =  new Fx.Slide('cad_escalade', {duration: 250});
obj_cad_escalade.hide();


obj_hummer_h2 =  new Fx.Slide('hummer_h2', {duration: 250});
obj_hummer_h2.hide();

obj_hummer_h3 =  new Fx.Slide('hummer_h3', {duration: 250});
obj_hummer_h3.hide();


function toggle(e_id) {
	 t = setTimeout(e_id+".slideIn()", 300);
}

function toggle_out(e_id) {
	clearTimeout(t);
}




function s_tm(e_id) {
	 v = setTimeout(e_id+".slideOut()", 50); 
}

function cl_tm() {
	 	clearTimeout(v);
}

function s_tm2(e_id) {
	 n = setTimeout(e_id+".slideOut()", 50); 
}

function cl_tm2(e_id) {

	if (e_id == c_name) {
		
	 clearTimeout(n);
	}
}


function d_on(d) {
	
	document.getElementById(d).style.display='block';
}

