var pathExpressInstallFile = escape(domein + "/lib/flash/expressInstall.swf");
var flashHeight;
var viewportHeight;


function initContentFlash() {
	var so = new SWFObject(domein+"/lib/flash/ArchitectenWedstrijd.swf", "architecten", "100%", "100%", "10", "#FFFFFF");
   
    so.addParam("wmode", "window");
    so.addParam("scale", "noscale");
    so.useExpressInstall(domein + '/lib/flash/expressinstall.swf');
    so.addVariable("defaultFontPath", "/lib/flash/");
    so.addVariable("contentXmlPath", "/lib/xml/");
    so.addVariable("architectName", strArchitectName);
    so.addVariable("introPath", '/lib/video/intro_2.flv');
    so.addVariable("taal", taal);
    so.addVariable("domein", domein);
    so.write("flashcontainer");

}
function setViewportHeight() {  
    if (typeof window.innerWidth != 'undefined') {
        // the more standards compliant browsers (mozilla/netscape/opera/IE7) use window.innerWidth and window.innerHeight
        viewportHeight = window.innerHeight
    } else if (typeof document.documentElement != 'undefined' && typeof document.documentElement.clientWidth != 'undefined' && document.documentElement.clientWidth != 0) {
        // IE6 in standards compliant mode (i.e. with a valid doctype as the first line in the document)			  
        viewportHeight = document.documentElement.clientHeight
    } else {
        // older versions of IE				  
        viewportHeight = document.getElementsByTagName('body')[0].clientHeight
    } 
}
function setFlashHeight(height) {
    flashHeight = height
    setViewportHeight();
    checkHeight(height);
}
function checkHeight(height) {
    if (height < viewportHeight) {
        $('#flashcontainer').css('height', '100%');
    } else {
        $('#flashcontainer').css('height', height);
    }
}
$(document).ready(function() {

    //Initialiseer hier je scripts
    initContentFlash();
       
    window.onresize = function() {
        setViewportHeight();
        checkHeight(flashHeight);
    }
});

