var images = new Array(); function preload() { for (i = 0; i < preload.arguments.length; i++) { images[i] = new Image(); images[i].src = preload.arguments[i]; console.log("preload file: " + preload.arguments[i]); } } preload( "img/odyssey_03-1.jpg", "img/odyssey_03-1.jpg" ); $(document).ready(function() { $("#iconVideo").mouseenter(function(event) { $("#hotspoticonVideo").fadeIn(250); }); $("#hotspoticonVideo").mouseleave(function(event) { $("#hotspoticonVideo").fadeOut(500); }); $("#openVideo").click(function(e){ console.log("open video"); e.preventDefault(); var elm = $(this).hide(); $("#bloco02 video").show(); $("#bloco02").addClass("bloco02On"); var mediaPlayer; mediaPlayer = document.getElementById('video-dragao'); mediaPlayer.controls = false; mediaPlayer.play(); }); $("#bloco03 .setas a").click(function(e){ e.preventDefault(); //$("#isee-conteudo-samsung-odyssey .section-bg-3").toggleClass("alt"); var target = parseInt($(this).attr("data-target")) == 5 ? 1 : parseInt($(this).attr("data-target")); var next = target + 1; var prev = target == 1 ? 4 : target - 1; $("#bloco03").removeClass("bloco03Bg1"); $("#bloco03").removeClass("bloco03Bg2"); $("#bloco03").removeClass("bloco03Bg3"); $("#bloco03").removeClass("bloco03Bg4"); $("#bloco03").addClass("bloco03Bg"+target); $("#bloco03 .setas a.isee-next").attr("data-target", next.toString()); $("#bloco03 .setas a.isee-prev").attr("data-target", prev.toString()); }); $("#bloco05 .isee-controls li a").click(function(e){ e.preventDefault(); $("#bloco05 .isee-controls li").removeClass("active"); $(this).parent().addClass("active"); var selected = $(this).attr("data-value"); $("#bloco05").removeClass("bloco05fullhd"); $("#bloco05").removeClass("bloco05antireflexo"); $("#bloco05").removeClass("bloco05hdr"); $("#bloco05").addClass(selected); }); //BLOCO 04 $("#btnBl04Upgrade").click(function(){ $("#bloco04GerTermico").hide(); $("#bloco04Upgrade").show(); }); $("#btnBl04GerTermico").click(function(){ $("#bloco04GerTermico").show(); $("#bloco04Upgrade").hide(); }); $('.hotspotMemoriaBt').click(function(){ $('.hotspotMemoria').show(); $('.hotspotMemoriaBt').hide(); }); $('.hotspotMemoriaClose').click(function(){ $('.hotspotMemoria').hide(); $('.hotspotMemoriaBt').show(); }); $('.hotspotssdBt').click(function(){ $('.hotspotSSD').show(); $('.hotspotssdBt').hide(); $('.hotspotMemoriaBt').hide(); }); $('.hotspotSSDClose').click(function(){ $('.hotspotSSD').hide(); $('.hotspotMemoriaBt').hide(); $('.hotspotssdBt').show(); $('.hotspotMemoriaBt').show(); }); });