﻿var ClickedItem, CurrentItem, WaitForDisappear, WaitForDisplayNone;

$(document).ready(function() {
//    $('#MainMenu .MainMenuItem').click(function() {
//        ClickedItem = $(this);

//        WaitForDisappear = 500;
//        WaitForDisplayNone = 200;

//        $('#MainMenu .MainMenuItem').each(function() {
//            if ($(this).attr('id') != $(ClickedItem).attr('id')) {
//                $(this).animate(
//								{ filter: 'alpha(opacity=0)', opacity: '0' },
//								WaitForDisappear,
//								null,
//                /* Callback */
//								function() {
//								    $(this).animate({ padding: 0, margin: 0, width: 0 }, WaitForDisplayNone, null, function() {
//								        $(this).css("display", "none");
//								        $(this).addClass('Clear');
//								    });
//								});
//            }
//        });
//        $(ClickedItem).addClass('NoBorder');

//        setTimeout("ShowSubMenuItem()", (WaitForDisappear + WaitForDisplayNone) * 1.2);
//    });
    

    //$('.FooterLogo img').hover(function() { $(this).attr("src", $(this).attr("src").replace(".", "_active.")) }, function() { $(this).attr("src", $(this).attr("src").replace("_active.", ".")) });

    //swfobject.embedSWF("swf/loadContent.swf", "FlashBannerObject", "960", "376", "9.0.0", null, null, { wmode: "transparent" });

    //swfobject.embedSWF("swf/menu.swf", "MainMenu", "556", "52", "10.0.0", null, null, { wmode: "transparent" });
    if ($('#hdnPage').val() != null) {
					menuControl($('#hdnPage').val());
				}

    $("#BannerBunlariBiliyorText").easySlider({ /*waitFor: 1000*/ });
});

function ShowSubMenuItem() {
    //$(ClickedItem).addClass("ClearSides");
    $('#ul_' + $(ClickedItem).attr('id') + '').show();
} 

//<script type="text/javascript">
//			$(document).ready(function() {
//				if ($('#hdnPage').val() != null) {
//					menuControl($('#hdnPage').val());
//				}
//			});
//			function menuControl(pageNumber) {
//				swfobject.embedSWF("swf/menu.swf", "MainMenu", "556", "52", "10.0.0", { FlashVars: "pages=" + pageNumber }, null, { wmode: "transparent" });
//				alert('Gönderdi');
//			}
//		</script>
//function menuControl(pageNumber) {
//    swfobject.embedSWF("swf/menu.swf?pages=" + pageNumber, "MainMenu", "556", "52", "10.0.0", { pages: " + pageNumber + " }, null, { wmode: "transparent" , pages:'"+ pageNumber +"'});
//}

