<%@ language="javascript"%>
<% /*
     $Revision$
     $Modtime: 13-01-12 19:59 $

    File:               fullscreen.asp
    Description:        Toont een plattegrond in een full size window
    Parameters:         Allerlei custom parameters die aangeven wat er getoond moet worden
    Context:
    Note:
*/
 %>
<!--#include file="../Shared/common.inc" -->
<!--#include file="../slnkdwf/Slnk2IMG.inc" -->
<%
  FCLTHeader.Requires({ plugins: ["jQuery"],
                        js: ["jquery-ui.js"],
                        css: []});

//SAMPLE: http://sgf12/facilitor500/?fac_id=AKZA&API=RESPLAN&APIKEY=206C553F69AA428B
// leidt naar http://sgf12/facilitor500/appl/cad/fullscreen.asp?mode=0&vKey=10107&thema=41&label=61&discs=685&labelPos=1&scenario_key=0&refresh=6000
var refreshTime = getQParamInt("refresh", -1);
var labelPos = getQParamInt("labelPos", 2);
%>
<html style="overflow: hidden">
<head>
<%
       FCLTHeader.Title(L("lcl_facilitor_ie_title"));
       FCLTHeader.Generate();
%>
</head>

<script type="text/javascript">
function myRefresh()
{
    MMap.Reset();
    MMap.SetIMGGenerator("../CAD/mySlnk2IMG.asp");
    MMap.SetPaperColor(<%=S("fg_paperColor")%>);
    MMap.SetLabelPosition(<%=labelPos%>);
    MMap.SetCustomParameters("&<%=safe.jsstring(String(Request.ServerVariables("QUERY_STRING")))%>")

    MMap.Refresh(true, true); // Do zoom extents

    var refreshTime = <%=refreshTime%>;
    if (refreshTime > 1000) {
      setTimeout("myRefresh()", refreshTime);
    }
}

function resizeIframes()
{
    var height = $(window).height();
    document.getElementById('MMap').style.height = (height-0) +"px";
};

function init()
{
    resizeIframes();
    myRefresh();
    var timerID=null;
    window.onresize = function()
    {
    	if (timerID) clearTimeout(timerID);
        timerID = setTimeout(resizeIframes, 100);// use a delay for IE because the resize event fires repeatly
    }

}

</script>

<body onload="init();" style="border:0;padding:0;margin:0;overflow: hidden">
<div id='log' style='position:absolute;left: -10px'><img src="<%=custpath%>/tmpl_logo.gif"></div>
<iframe id=MMap name=MMap src='../SlnkDWF/ToonIMG.asp'
        frameborder='0' framespacing='0' scrolling='no' width='100%' height='100%' valign='center'>
</iframe>
</body>

</html>
