﻿$(function() {
    var lmID = $("#lmID").val();
    var mainLmID = lmID.substring(0, 2);
    var $mainMenu = $("#m" + mainLmID);
    $("#mainName").text($mainMenu.text());
    $("#mainLmID").text(mainLmID);
    if ($mainMenu.next()) $mainMenu.next().clone(true).appendTo("#columns").children().hoverClass("select").find("#m" + lmID).parent().addClass("active");
    if (lmID.substring(0,2)!="07") setTimeout(function() { (window["SoundSwf"] || document["SoundSwf"]).playSound("images/music.mp3", 10); }, 500);
    $("#menu li").hover(
		    function() { $("ul", this).show(); },
		    function() { }
    );
    if (document.all) {
        $("#menu li").hoverClass("sfHover");
    }
    $("a[href^='Detail.aspx']").click(function() { fullOpen(this); return false; });
});

function fullOpen(obj) {
    window.open($(obj).attr("href"), 'detail', 'width=' + window.screen.width + ',height=' + (window.screen.height - 20) + ',toolbar=no,location=no,directories=no,menubar=no,scrollbars=no,resizable=yes,status=no');
    return false;
}
