function playFilePreview(a){$(".file-name").removeClass("active"),getFlash().playURL(a.attr("preview")),current_file?current_file.get(0)!=a.get(0)&&a.addClass("active"):a.addClass("active"),current_file=a}function playPreview(a){preview=$(".preview",a),getFlash().playURL(preview.attr("preview")),current_preview?(current_preview.attr("src","http://assets.powerfx.com/assets/preview-85f38d23cd5e22569e485f6de8a09859.png"),current_preview.get(0)!=preview.get(0)&&current_preview.attr("preview")!=preview.attr("preview")?preview.attr("src","http://assets.powerfx.com/assets/preview-inactive-3210d70742a9601ce722e520c28f7f20.png"):preview=null):preview.attr("src","http://assets.powerfx.com/assets/preview-inactive-3210d70742a9601ce722e520c28f7f20.png"),current_preview=preview}function soundComplete(){current_preview&&current_preview.attr("src","http://assets.powerfx.com/assets/preview-85f38d23cd5e22569e485f6de8a09859.png"),current_preview=null,current_file=null,$(".file-name").removeClass("active")}function getFlash(){return navigator.appName.indexOf("Microsoft")!=-1?window.player:document.player}function checkAcceptLicense(){return $("#license_agree").attr("checked")?!0:(alert("Please read and agree to the license agreement."),$(".license-confirm").addClass("red"),!1)}var current_preview=null,current_file=null;$(document).ready(function(){$(".file-name").click(function(){playFilePreview($(this))}),$(".preview").click(function(){product=$(this).parent().parent(),playPreview(product)}),$("form.contact_new").submit(function(){return $("#contact_name").val()==""?(alert("You need to specify your name"),!1):$("#contact_email").val()==""?(alert("You need to specify your email address"),!1):$("#contact_message").val()==""?(alert("You need to specify a message"),!1):!0}),$(".cart.index table tr:nth-child(even)").addClass("ie-even"),$("table.products.index tr:nth-child(odd)").addClass("ie-odd"),$("#loops-and-samples").click(function(){window.location="/products/loops-and-samples-library"}),$("#sound-effects").click(function(){window.location="/products/sound-effects-library"})})
