$(document).ready(function(){$(".vid-box").mouseover(function(){$(this).siblings(".first-active").children(".vid-info").children().css("font-size","9px");$(this).siblings(".first-active").children(".vid-preview").children().children(".smallplay-preview-btn").animate({width:"20px"},0);$(this).siblings(".first-active").animate({width:"100px",opacity:"0.6"},0).removeClass("first-active");$(this).animate({width:"150px",opacity:"1"},0).addClass("first-active");$(this).children(".vid-preview").children().children(".smallplay-preview-btn").animate({width:"36px"},0);$(this).children(".vid-info").children().css("font-size","11px");$(this).children(".vid-info ul").css("font-size","12px");});var nbelements=$(".items > div").size();var widthSlides=nbelements*655;$(".items").css("width",widthSlides+"px");$("div.slider-frame").scrollable({size:nbelements+"-"+1});$(".prevPage").click(function(){var page=$(this).parent("#actions").siblings(".position-slider-txt").children(".items-count").html();if(page!=1){$(this).parent("#actions").siblings(".position-slider-txt").children(".items-count").html(page-1);}});$(".nextPage").click(function(){var page=$(this).parent("#actions").siblings(".position-slider-txt").children(".items-count").html();var maxpages=$(this).parent("#actions").siblings(".position-slider-txt").children(".max-pages").html();if(page!=maxpages){var current_page=parseInt(page)+1;$(this).parent("#actions").siblings(".position-slider-txt").children(".items-count").html(current_page);}});if($("#custombackground").html()){$('body').attr("style","background-image:none;background-color:"+$("#customBgColorValue").attr("title"));}});