﻿$(document).ready(function () {
    genelAyarlar();
    RefKaydir();
    urunleriKaydir();
    haberleriKaydir();
    urunMenusu();
    tabAyarla();

    //    AC_FL_RunContent(
    //		'codebase', 'http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=10,0,0,0',
    //		'width', '980',
    //		'height', '205',
    //		'src', 'slides/t-set-splash',
    //		'quality', 'high',
    //		'pluginspage', 'http://www.adobe.com/go/getflashplayer',
    //		'align', 'middle',
    //		'play', 'true',
    //		'loop', 'true',
    //		'scale', 'showall',
    //		'wmode', 'window',
    //		'devicefont', 'false',
    //		'id', 't-set-splash',
    //		'bgcolor', '#ffffff',
    //		'name', 't-set-splash',
    //		'menu', 'true',
    //		'allowFullScreen', 'false',
    //		'allowScriptAccess', 'sameDomain',
    //		'movie', 't-set-splash',
    //		'salign', ''
    //		);
});

function genelAyarlar() {
    $('.altSM').find('ul').each(function () {
        $(this).children('li:last-child').not('li:first-child').css('border', 'none');
    });

    $('.logo').click(function () {
        location.href = 'Default.aspx';
    });
}

function urunleriKaydir() {
    $(".kayanUrun").easySlider({
        auto: true,
        continuous: true,
        pause: 1500,
        speed: 800,
        prevId: 'grBt',
        nextId: 'nxBt',
        controlsShow: false
    });
}

function RefKaydir() {
    $(".RefCssClass").jCarouselLite({
        vertical: true,
        hoverPause: true,
        visible: 2,
        auto: 2000,
        speed: 2000
    });
}


function haberleriKaydir() {
    $(".kayan").easySlider({
        auto: true,
        continuous: true,
        pause: 5000,
        speed: 1000,
        prevId: 'grBt',
        nextId: 'nxBt',
        controlsShow: false
    });
}

function urunMenusu() {

}

function tabAyarla() {
    $('.tabCont').find('.tabItem:first').show();
    $('.tabBaslik').find('li:first').addClass('aktifTab');
    $('.tabBaslik').find('a').each(function () {
        $(this).bind({
            click: function () {
                $('.tabCont').find('.tabItem').hide();
                $('.tabCont').find('*[name="' + $(this).attr('href') + '"]').fadeIn('slow');
                $('.aktifTab').removeClass('aktifTab');
                $(this).parent().addClass('aktifTab');
                return false;
            }
        });
    });
}
