   var _auto_swith = true;
   var auto_timeout = 5000;      //m'seconds
   var default_auto_height = 60; //in px;
   var default_auto_height_margin_top = 0; //in px
   
   
   var auto_switcher_handler = "";
   var zero_count_trigger = "";
  
   function auto_switcher(){
     if(_auto_swith){
       var active = $('#text_box_wrapper').find('.text_box_active');
       var nast = $(active).next();  

       if( !$(nast).hasClass("text_box") ){
         nast = $('#text_box_wrapper div.text_box:first');
       }
       
       $(nast).trigger("przelacz");
     }
   }  
   
   function inside_przelacz(){
   
       if(_auto_swith){
         clearTimeout(auto_switcher_handler);
         auto_switcher_handler = setTimeout("auto_switcher()", auto_timeout);
       }
     
       if( !$(this).hasClass('text_box_active') ){
         var prev_active_box = $('#text_box_wrapper').find('.text_box_active').get(0);
         var new_active_box = $(this).get(0);
         
         $(prev_active_box).removeClass('text_box_active');
         $(new_active_box).addClass('text_box_active');
         
         var texts = $('#text_box_wrapper').children('.text_box');
         var imgs = $('#images_wrapper').children('img');
         
         var text_new_nr = 0;
         var text_prev_nr = 0;
         
         for(var a=0; a < texts.length; a++ ){
           if(texts[a] === new_active_box){
             text_new_nr = a + 1;
             break;
           }
         }
         
         for(var a=0; a < texts.length; a++ ){
           if(texts[a] === prev_active_box){
             text_prev_nr = a + 1;
             break;
           }
         }
         
         var new_active_img = "";
         var prev_active_img = $('#images_wrapper').find('.active').get(0);
         var images = $('#images_wrapper').children('img');
         for(a=0; a<images.length; a++){
            if(a == text_new_nr - 1){
              new_active_img = images[a];
              break;
            }
         }
         
         $(new_active_img).addClass('new_to_show');
         $(prev_active_img).removeClass("active");
         $(new_active_img).addClass('active');
         $(new_active_img).removeClass('new_to_show');
               
       }      
   }
   
   function text_box_auto_height(){
     var text_box_height = $('.text_box_active').height();
     
     var inside = "";
     var roznica = "";
     var margintop = "";
     var temp = "";
     
     var teksty = $('#text_box_wrapper .text_box').children('.text_box_inside');
     for(var a=0; a<teksty.length; a++){
       inside = $(teksty[a]).height();
       temp += inside;
       /*
       if(inside >= 50){
         $(teksty[a]).css("marginTop", default_auto_height_margin_top);
         $(teksty[a]).css("height", default_auto_height);
       }else
       if(inside < 50 && inside != 0){
         roznica = text_box_height - inside;
         margintop = roznica/2;
         margintop = Math.floor(margintop);
         $(teksty[a]).css("marginTop", margintop); 
       }*/
       
     }
     
   }
   
   //var _auto_swith = true;
   //var auto_timeout = 3000;      //m'seconds
   //var default_auto_height = 36; //in px;
   //var default_auto_height_margin_top = 7; //in px
   
   function switcher_init(){
   
   
     var zero_count_trigger = $('#text_box_wrapper').children('.text_box');
     if(zero_count_trigger !== "undefined" && zero_count_trigger !== 0 && zero_count_trigger !== null){
   
       text_box_auto_height();
   
       if(_auto_swith){
         auto_switcher_handler = setTimeout("auto_switcher()", auto_timeout);
       }         
     
       $('.text_box').bind('przelacz', inside_przelacz ); 
     
       $('.text_box, #images_wrapper').bind('mouseover', function(){
         $(this).trigger("przelacz");
         clearTimeout(auto_switcher_handler);
       });
     
       $('.text_box, #images_wrapper').bind('mouseout', function(){
         $(this).trigger("przelacz");
         clearTimeout(auto_switcher_handler);
         auto_switcher_handler = setTimeout("auto_switcher()", auto_timeout);
       });
    
     }
     
   }
