$(document).keydown( function( e ) { 
   if( e.which == 27) {  // escape, close box 
     $("#dialog").jqmHide(); 
   } 
 }); 
$(document).ready(function() {
/*
if($.browser.msie && $.browser.version=="6.0")
{
	$(this).oneTime(10000, function() {
   		$('#dialog').jqm({overlay: 40, modal: false}).jqDrag('.jqDrag').jqmShow();
  	});
}
else
	$('#dialog').jqm({overlay: 40, modal: false}).jqDrag('.jqDrag').jqmShow();
*/
$("a.galeri").fancybox();

$(this).oneTime(1000, function() {
	$('#buyukResim').codaSlider({
			autoSlide: true,
           	autoSlideInterval: 5000,
           	autoSlideStopWhenClicked: true,
			dynamicArrows: false,
			dynamicTabs: false
       });
});
function addMega(){
  $(this).addClass("hovering");
  }

function removeMega(){
  $(this).removeClass("hovering");
  }
  var megaConfig = {    
     interval: 100,
     sensitivity: 4,
     over: addMega,
	 timeout: 100,
     out: removeMega
     };
  
  
  $('.rollover').hover(function() {
	var currentImg = $(this).attr('src');
	$(this).attr('src', $(this).attr('hover'));
	$(this).attr('hover', currentImg);
	}, function() {
	var currentImg = $(this).attr('src');
	$(this).attr('src', $(this).attr('hover'));
	$(this).attr('hover', currentImg);
  });
  
});

