add: dojo.debug("closed popup."); 
context: function openPopup(url, width, height, formid, action, loadfunc) {  closePopup();  var objOverlay = document.getElementById("dialogoverlay");  if(!objOverlay)  {	var objBody = document.getElementsByTagName("body").item(0);	objOverlay = document.createElement("div");	objOverlay.setAttribute('id','dialogoverlay');	objOverlay.onclick = function () {closePopup(); return false;}	objOverlay.style.display = 'none';	objOverlay.style.position = 'absolute';	objOverlay.style.top = '0';	objOverlay.style.left = '0';	objOverlay.style.zIndex = '90'; 	objOverlay.style.width = ((dojo.html.getViewportWidth() + dojo.html.getScrollLeft() + 10) || 2000) + "px";	objBody.insertBefore(objOverlay, null);  }	var arrayPageSize = getPageSize();	var arrayPageScroll = getPageScroll();	// set height of Overlay to take up whole page and show	objOverlay.style.height = (arrayPageSize[1] + 'px');        dojo.debug("page height: " + arrayPageSize[1]);        dojo.debug("page width: " + objOverlay.style.width);	objOverlay.style.display = 'block';var block = document.getElementById("popup");if (!block) {var body = dojo.html.body();block = document.createElement("div");block.setAttribute("id", "popup");block.className = "rounded rc-parentcolor-404040";block.style.display = "none";block.style.position = "absolute";block.style.width = width;if(height)  block.style.height= height;//block.style.padding;block.style.zIndex = "400";block.style.background = "Window";block.style.backgroundColor = "#FFEB99";body.appendChild(block);}var block1 = document.getElementById("popup_close");if(!block1){  block1 = document.createElement("div");  block1.style.padding="0px";  block1.style.textAlign = "right";  block1.style.width="100%";  block1.setAttribute("id", "popup_close");  block1.innerHTML="<a href=\"#\" onclick=\"closePopup(); return false;\"><img border=\"0\" src=\"/static/images/close.gif\"></a> &nbsp;";  block.appendChild(block1);}var block2 = document.getElementById("popup_contents");if(!block2){  block2 = document.createElement("div");  block2.style.padding="0px 20px 20px 20px";  block2.setAttribute("id", "popup_contents");  block.appendChild(block2);}var bindArgs = {     url:        url,      content: {ajax: "1"},    method: "POST",    mimetype:   "text/plain",    error:      function(type, errObj){      alert("error");    },    load:      function(type, data, evt){        // handle successful response here     block2.innerHTML = data.toString();     objOverlay.style.width = dojo.html.getViewportWidth() + dojo.html.getScrollLeft() + 10;     var h = block.offsetHeight || block.style.pixelHeight ||                (block.currentStyle && block.currentStyle.height) || block.height;     if(h && dojo.lang.isNumber(h)) h = ((dojo.html.getViewportHeight()) - h) / 2       else h = 20;     var blockTop = dojo.html.getScrollTop() + h;        h = block.offsetWidth || block.style.pixelWidth ||               (block.currentStyle && block.currentStyle.width) || block.width;     if(h && dojo.lang.isNumber(h)) h = ((dojo.html.getViewportWidth()) - h) / 2       else h = 20;     var blockLeft = dojo.html.getScrollLeft() + h;		block.style.top = (blockTop < 0) ? "0px" : blockTop + "px";		block.style.left = (blockLeft < 0) ? "0px" : blockLeft + "px";     make_corners();dojo.debug("made corners.");     dojo.fx.html.fadeShow(block, 200, function(){				arrayPageSize = getPageSize();		objOverlay.style.width = (arrayPageSize[2] + 'px');		objOverlay.style.height = (arrayPageSize[1] + 'px');dojo.debug("showing item.");     if(loadfunc) loadfunc();});	// After image is loaded, update the overlay height as the new image might have	// increased the overall page height.    }  };  if(formid)  {    var form = document.getElementById(formid);    if(form)      bindArgs.formNode = form;    if(action && form)    {      document.getElementById("action").value=action;    }  }// dispatch the request    var requestObj = dojo.io.bind(bindArgs);   }
meta: 1857	/local1/tlutelli/issta_data/temp/all_js/javascript/2006_temp/2006/1857/516705b8f0b226d950d4b984f1f7bd320363a288/menulayer.js/buggy/static/javascripts/menulayer.js