
var cp_tmp_height=0;

var cp_max_height=356;

 

var cp_parent_name="cPush";

var cp_timeOut;

 

var delayPush;

var delayCount = 0;

 

var flashHTML = '';

 

function f4d_expand_layer(){

                clearTimeout(cp_timeOut);

                if(cp_tmp_height == 0 && flashHTML != '') {

                                document.getElementById(cp_parent_name).innerHTML = flashHTML;

                }

                with(document.getElementById(cp_parent_name).style){

                                  cp_tmp_height=cp_tmp_height+10;

                                  if(cp_tmp_height<=cp_max_height){

                                                                display="block";

                                                height=cp_tmp_height+"px";

                  cp_timeOut=setTimeout('f4d_expand_layer()',10);      

                                  }

                }

}

 

function f4d_collapse_layer(){

                 clearTimeout(cp_timeOut);

                 with(document.getElementById(cp_parent_name).style){

                                  cp_tmp_height=cp_tmp_height-10;

                                  if(cp_tmp_height>=5){

                                                height=cp_tmp_height+"px";

                cp_timeOut=setTimeout('f4d_collapse_layer()',10);       

                                  }

                                  else if(cp_tmp_height==0){

                                                                flashHTML = document.getElementById(cp_parent_name).innerHTML;

                                                                                                                    document.getElementById(cp_parent_name).innerHTML = '';

                                                height="0px";

                                                                display="none";

                                  }

                }              

}

 

 

function f4d_init_expand_layer(){

                if(document.getElementById(cp_parent_name)){

                                if(delayCount == 0) {

      delayPush = setTimeout('f4d_expand_layer()', 1000);

    } else {

                                                f4d_expand_layer();

                                }

                }

}

 

function f4d_init_collapse_layer(){

                clearTimeout(delayPush);

  delayCount = 0

                if(document.getElementById(cp_parent_name)){

    f4d_collapse_layer();

  }

}

 

