
/* CHIPMASTER | FUNCTIONS ####################### */
/* created 08.06.2010 by spielersun ############# */


$(document).ready(function(){
    $('#content').css("width",$(window).width()-176)
    
    $(window).resize(function() {
        $('#content').css("width",$(window).width()-176)
    });
    
    $(function() {
	// setup player normally
	$f("player_alter", {src: 'swf/flowplayer-3.2.2.swf', wmode: 'transparent'}, {
//		// clip properties common to all playlist entries
//		clip: {
//			baseUrl: 'http://blip.tv/file/get',
//			subTitle: 'from blib.tv video sharing site',
//			time: '20 sec'
//		},
		// our playlist
		playlist: [
		    {
				url: 'swf/video_alternate_03.flv',
				css: 'alterVideo3',
				title: 'Birol ATV Haberde.'
			},
			{
				url: 'swf/video_alternate_01.flv',
				css: 'alterVideo1',
				title: 'ChipMaster Birol'
			},	
			{
				url: 'swf/video_alternate_02.flv',
				css: 'alterVideo2',
				title: 'Soru-Cevap Birol.'
			}
			
		],
		// show playlist buttons in controlbar
		plugins: {
			controls: {
				playlist: true
			}
		}
	});
	
	/*
		here comes the magic plugin. It uses first div.clips element as the 
		root for as playlist entries. loop parameter makes clips play
		from the beginning to the end.
	*/
	$f("player_alter").playlist("div.nav:first", {loop:true});
	
});
    
//    $('div#video_2').hide();
//    
//    $('.alterVideo1').click(function(event) {
//        event.preventDefault();
//        $('div#video_2').hide();
//        $('div#video_1').show();
//    });
//    
//    $('.alterVideo2').click(function(event) {
//        event.preventDefault();
//        $('div#video_1').hide();
//        $('div#video_2').show();
//    });
    
    $(function(){$('input#txtName').focus(
        function() {if($(this).val() == 'Ad, Soyad'){
                    $(this).val('');}});});
                    
    $(function(){$('input#txtMail').focus(
        function(){if($(this).val() == 'E-Mail'){
                    $(this).val('');}});});
                    
    $(function(){$('input#txtName').blur(
        function(){if($(this).val() == ""){
                    $(this).val('Ad, Soyad');}});});
        
    $(function(){$('input#txtMail').blur(
        function(){if($(this).val() == ""){
                    $(this).val('E-Mail');}});});
                    
    $(".gameGo").colorbox();
    $(".kimdiGo").colorbox();
    $(".magazine_go").colorbox();
    $("a.nasilGo[rel='img_nasil']").colorbox();
   
    $.ifixpng('../css/images/pixel.gif');
        $('.pngfix').ifixpng();
});
