// JavaScript Document
//Voor home

$(document).ready(function(){
$('#opdrachtgeverbalk a').tooltip({ 
    track: true, 
    delay: 0, 
    showURL: false, 
    showBody: " - ", 
    fade: 250,
	top: -50, 
    left: -30
});

jQuery('#mycarousel').jcarousel({
        // Configuratie gaat hier
    });
});



//tooltip medewerkerspagina 
$(document).ready(function(){
$('#medewerkers a').tooltip({ 
    track: true, 
    delay: 0, 
    showURL: false, 
    showBody: " - ", 
    fade: 250,
	top: -50, 
    left: -30
});
});


//configuratie meer weten balk
$(document).ready(function(){
$('#meerweten a').tooltip({ 
    track: true, 
    delay: 0, 
    showURL: false, 
    showBody: " - ", 
    fade: 250,
	top: -50, 
    left: -30
});

$('#meerweten2 a').tooltip({ 
    track: true, 
    delay: 0, 
    showURL: false, 
    showBody: " - ", 
    fade: 250,
	top: -50, 
    left: -30
});

jQuery('#mycarousel').jcarousel({
        // Configuratie gaat hier
    });
});

jQuery(document).ready(function() {
    // Initialise the first and second carousel by class selector.
	// Note that they use both the same configuration options (none in this case).
	jQuery('.tweecarousels').jcarousel();
	
	
});



//<![CDATA[

// STAAT ALLEGAAR AL IN EEN CHUNK IN MODX (jsGallery)

//jQuery(function($) { 
//$('ul.gallery').galleria(
//{insert: "#linksimg",
//history   : false,
//clickNext : false,
//onImage   : function(image,caption,thumb) {
//
//if(! ($.browser.mozilla && navigator.appVersion.indexOf("Win")!=-1) ) { // FF/Win fades large images terribly slow
//					image.css('display','none').fadeIn(1500);
//					// fetch the thumbnail container
//				var _li = thumb.parents('li');
//				
//				// fade out inactive thumbnail
//				_li.siblings().children('img.selected').fadeTo(500,0.3);
//				
//				// fade in active thumbnail
//				thumb.fadeTo('fast',1).addClass('selected');
//			
//			
//			//#check if thumbnail indicates that a large version of this pic is available
//				var large = thumb.attr('longdesc');
//				if(large)
//				{
//				//#if so, link to it and show it in a lightbox
//				image.wrap('<a rel="shadowbox[Mixed]" href="' + large + '></a>');
//				image.parent('a').shadowbox();
//				}
//
//
//			}},
//			
//onThumb : function(thumb) { // thumbnail effects goes here
//				
//				// fetch the thumbnail container
//				var _li = thumb.parents('li');
//				
//				// if thumbnail is active, fade all the way.
//				var _fadeTo = _li.is('.active') ? '1' : '0.3';
//				
//				// fade in the thumbnail when finnished loading
//				thumb.css({display:'none',opacity:_fadeTo}).fadeIn(1500);
//				
//				// hover effects
//				thumb.hover(
//					function() { thumb.fadeTo('fast',1); },
//					function() { _li.not('.active').children('img').fadeTo('fast',0.3); } // don't fade out if the parent is active
//				)
//			}
//
//}); 
//
//});
//							   
//// Hieronder later es goed uitzoeken. Eventueel nodig voor direct starten van een slideshow 
///*$(function() { 
//				//var slideshow = $("gallerytitle");
//				
//				var active = true;
//				var gal = jQuery('#linksnav');
//				gal.find('.start').css("cursor", "pointer").click(function() {
//					if (!active) {
//						active = !active;
//						$.galleria.next();
//						gal.everyTime('1s', 'slideshow', function() {
//							$.galleria.next();
//						});
//					}
//				});
//				//}).end().find('.stop').css("cursor", "pointer").click(function() {
//				gal.find('.stop').css("cursor", "pointer").click(function() {
//					if (active) {
//						active = !active;
//						gal.stopTime('slideshow');
//					}
//				});
//		});*/
//	    
// 
//    //]]>
//
///* IE 6 PNG fix */
////fix voor PNG
//
//function correctPNG() // correctly handle PNG transparency in Win IE 5.5 & 6.
//{
//   var arVersion = navigator.appVersion.split("MSIE")
//   var version = parseFloat(arVersion[1])
//   if ((version >= 5.5) && (document.body.filters)) 
//   {
//      for(var i=0; i<document.images.length; i++)
//      {
//         var img = document.images[i]
//         var imgName = img.src.toUpperCase()
//         if (imgName.substring(imgName.length-3, imgName.length) == "PNG")
//         {
//            var imgID = (img.id) ? "id='" + img.id + "' " : ""
//            var imgClass = (img.className) ? "class='" + img.className + "' " : ""
//            var imgTitle = (img.title) ? "title='" + img.title + "' " : "title='" + img.alt + "' "
//            var imgStyle = "display:inline-block;" + img.style.cssText 
//            if (img.align == "left") imgStyle = "float:left;" + imgStyle
//            if (img.align == "right") imgStyle = "float:right;" + imgStyle
//            if (img.parentElement.href) imgStyle = "cursor:hand;" + imgStyle
//            var strNewHTML = "<span " + imgID + imgClass + imgTitle
//            + " style=\"" + "width:" + img.width + "px; height:" + img.height + "px;" + imgStyle + ";"
//            + "filter:progid:DXImageTransform.Microsoft.AlphaImageLoader"
//            + "(src=\'" + img.src + "\', sizingMethod='scale');\"></span>" 
//            img.outerHTML = strNewHTML
//            i = i-1
//         }
//      }
//   }    
//}
//window.attachEvent("onload", correctPNG);
