var popup_open_failed = null; function popup_open() { var _argv = popup_open.arguments; if ( typeof($GLOBALS["popup"]) == "undefined" ) { $GLOBALS["popup"] = new Array(); } if ( typeof($GLOBALS["zmax"]) == "undefined" ) { $GLOBALS["zmax"] = 1; } var p = $GLOBALS["popup"].length; if ( _argv.length == 1 ) { var erg = new _P_popup(p); $GLOBALS["popup"][p] = erg; if ( typeof(_argv[0]) == "string" ) { erg.init({url:_argv[0]}); } else if ( typeof(_argv[0]) == "object" ) { erg.init(_argv[0]); } return erg; } else if ( _argv.length == 0 ) { var erg = new _P_popup(p); $GLOBALS["popup"][p] = erg; erg.init(); return erg; } else if ( _argv.length == 2 ) { if ( _argv[1] == "fail" ) { var erg = $GLOBALS["popup"][_argv[0]]; if ( erg ) { erg.display("fail"); popup_open_failed = null; } } } return erg; } function popup_close() { var _argv = popup_close.arguments; if ( typeof(_argv[0]) == "object" ) { if ( _argv.length > 1 ) { var nr = popup_control(_argv[0],true); window.setTimeout("popup_close("+nr+")",_argv[1]); } else { var erg = popup_control(_argv[0]); erg.close(); } } else { if ( $GLOBALS["popup"][_argv[0]] ) { $GLOBALS["popup"][_argv[0]].close(); } } } function popup_delete(e) { if ($GLOBALS["popup"].length > 0) { for (var i=0; i<$GLOBALS["popup"].length; i++) { if ($GLOBALS["popup"][i] == e ) { $GLOBALS["popup"][i] = null; $GLOBALS["popup"].splice(i,1); break; } } } } function popup_control(e,ctrl) { var _argv = popup_control.arguments; if ( typeof(e) == "object" ) { if ( e.name ) { var a = e.name.split("_"); if ( a[0] == "iframe" ) { var nr = a[1]; if ( $GLOBALS["popup"][nr] ) { $GLOBALS["popup"][nr].window(_argv[0]); if ( _argv.length == 1 ) { return $GLOBALS["popup"][nr]; } else if ( typeof(_argv[1]) == "boolean" ) { return nr; } else if ( typeof(_argv[1]) == "object" ) { var val = _argv[1] var obj = $GLOBALS["popup"][nr]; for ( var key in val ) { obj[key]( val[key] ); } return $GLOBALS["popup"][nr]; } } } return null; } else { var div = _argv[0]; while (div.tagName != "HTML") { if (div.name && div.name.indexOf("_") > 0) { var a = div.name.split("_"); if ( a[0] == "popup" ) { return $GLOBALS["popup"][a[1]]; } } do { div = div.parentNode; } while (typeof(div.tagName) == "undefined"); if (div.tagName == "HTML") break; } } } } function _P_popup(p) { var $ = {}; $.box = null; $.title = null; $.close = null; $.contents = null; $.overlay = null; $.rightBorder = null; $.bottomBorder = null; $.rbBorder = null; $.brBorder = null; $.iframe = false; $.window = null; $.inhibit = null; var _ = []; var my = null; var params = {}; var listener = {}; _.nr = p; _.resize = null; _.offsX = 0; _.offsY = 0; _.cursor = "default"; _.closed = null; var popup_open_failed = null; this._P_resize_X_callback = function(evt) { if ( params["left"] == "center" ) { my.left("center"); } if ($.inhibit !== null) { $.inhibit.style.width = window.innerWidth + "px"; } } this._P_resize_Y_callback = function(evt) { if ( params["top"] == "middle" ) { my.top("middle"); } if ($.inhibit !== null) { $.inhibit.style.height = window.innerHeight + "px"; } } this.identTarget = function(obj) { for (var divs in $) { if ($[divs] == obj) { return divs; } } if (obj.id) { return obj.id; } else if (obj.name) { return obj.name; } else { return "not identified"; } } this._P_click_callback = function(evt) { var my_event = ( evt ) ? evt : window.event; if ( my_event.preventDefault ) my_event.preventDefault(); my_event.stopPropagation(); if ( my_event.type == "click" ) { my.close(); } } this._P_mousemove_callback = function (evt) { var my_event = ( evt ) ? evt : window.event; var obj = my_event.target; var my_target = my.identTarget(obj); var x = my_event.pageX - _.offsX; var y = my_event.pageY - _.offsY; if ( _.resize == 0 ) { if ( params["left"] == "center" || params["exclusive"] === true ) { my._P_deleteEventListener(window,"resize",my._P_resize_X_callback,"window"); } $.box.style.left = x + "px"; params["left"] = x; if ( params["top"] == "middle" || params["exclusive"] === true ) { my._P_deleteEventListener(window,"resize",my._P_resize_Y_callback,"window"); } if ( y > 0 ) { $.box.style.top = y + "px"; params["top"] = y; } if ( my_target == "overlay" ) { if ( _.cursor != "move" ) { _.cursor = "move"; obj.style.cursor = "move"; } } } else { if ( ( _.resize & 1 ) == 1 ) { var width = parseInt($.box.style.width,10) + x; if ( width > 100 ) { _.offsX += x; my.width(width,false); } } if ( ( _.resize & 2 ) == 2 ) { var height = parseInt($.box.style.height,10) + y; if ( height > 100 ) { _.offsY += y; my.height(height,false); } } } } this.mouseout_callback = function (evt) { var my_event = ( evt ) ? evt : window.event; var obj = my_event.target; my_target = my.identTarget(obj); if (my_target == "overlay") { my._P_mouseup_callback(my_event); } } this._P_mouseup_callback = function (evt) { var my_event = ( evt ) ? evt : window.event; var obj = my_event.target; var my_target = my.identTarget(obj); if ( my_event.preventDefault ) my_event.preventDefault(); my_event.returnValue = false; my_event.stopPropagation(); if ( my_target == "overlay" ) { my._P_deleteEventListener($.overlay,"mousemove",my._P_mousemove_callback,"overlay"); my._P_deleteEventListener($.overlay,"mouseover",my.mouseover_callback,"overlay"); my._P_deleteEventListener($.overlay,"mouseup",my._P_mouseup_callback,"overlay"); document.body.removeChild(obj); } } this._P_mousedown_callback = function (evt) { var my_event = ( evt ) ? evt : window.event; var obj = my_event.target; var my_target = my.identTarget(obj); if ( my_event.preventDefault ) my_event.preventDefault(); my_event.returnValue = false; my_event.stopPropagation(); $.overlay = document.createElement("div"); $.overlay.style.position = "absolute"; $.overlay.style.top = 0; $.overlay.style.left = 0; $.overlay.style.height = document.body.scrollHeight + "px"; //window.innerHeight + "px"; $.overlay.style.width = document.body.scrollWidth + "px"; //window.innerWidth + "px"; $.overlay.style.backgroundColor = "rgb(0,0,0)"; $.overlay.style.opacity = "0.01"; $.overlay.style.zIndex = (parseInt(params["zindex"]) +2+ (_.nr * 3)); my._P_installEventListener($.overlay,"mousemove",my._P_mousemove_callback,"overlay"); my._P_installEventListener($.overlay,"mouseover",my.mouseover_callback,"overlay"); my._P_installEventListener($.overlay,"mouseup",my._P_mouseup_callback,"overlay"); my._P_installEventListener($.overlay,"mouseout",my.mouseout_callback,"overlay"); document.body.appendChild($.overlay); if ( my_target == "title" ) { _.offsX = my_event.layerX; _.offsY = my_event.layerY; _.resize = 0; _.cursor = "move"; if (params["parent"] != document.body) { var e = params["parent"]; var X_add = e.offsetLeft; var Y_add = e.offsetTop; _.offsX += X_add; _.offsY += Y_add; } } else if ( my_target == "rightBorder" ) { _.offsX = my_event.pageX; _.resize = 1; _.cursor = "e-resize"; } else if ( my_target == "bottomBorder" ) { _.offsY = my_event.pageY; _.resize = 2; _.cursor = "n-resize"; } else if ( my_target == "rbBorder" || my_target == "brBorder" ) { _.offsX = my_event.pageX; _.offsY = my_event.pageY; _.resize = 3; _.cursor = "se-resize"; } else { _.cursor = "default"; } $.overlay.style.cursor = _.cursor; } this._P_onload = function() { if ( popup_open_failed != null ) { my.display("view"); } } this._P_installEventListener = function(obj,evt,fkt,nn) { var _id = ( obj.id ) ? obj.id + "[" + _.nr + "]" : nn + "[" + _.nr + "]"; if ( obj.addEventListener ) { obj.addEventListener (evt, fkt, false); } else if ( obj.attachEvent ) { obj.attachEvent( "on" + evt, fkt) } else { var ie4_evt = "on" + evt; obj[ie4_evt] = fkt; } if (typeof(listener[nn]) == "undefined") listener[nn] = {}; listener[nn][evt] = true; } this._P_deleteEventListener = function(obj,evt,fkt,nn) { var _id = ( obj.id ) ? obj.id + "[" + _.nr + "]" : nn + "[" + _.nr + "]"; if ( obj.removeEventListener ) { obj.removeEventListener (evt, fkt, false); } else if (obj.detachEvent) { obj.detachEvent( "on"+evt, fkt) } listener[nn][evt] = false; } this.top = function(value) { var _shiftY = (params["parent"] == document.body) ? document.body.scrollTop:0; if ( value == "middle" ) { var _top; if (params["parent"] == document.body) { _top = ( parseInt(window.innerHeight) - parseInt($.box.style.height,10) ) / 2; } else { _top = ( parseInt(params["parent"].clientHeight ) - parseInt($.box.style.height) ) / 2; } var real_top = Math.max( Math.floor(_top) + _shiftY, 0 ); $.box.style.top = ( real_top ) + "px"; if ( params["top"] != "middle" ) { my._P_installEventListener(window,"resize",my._P_resize_Y_callback,"window"); params["top"] = "middle"; } } else { if ( params["top"] == "middle" ) { my._P_deleteEventListener(window,"resize",my._P_resize_Y_callback,"window"); } var real_top = Math.max(value + _shiftY, 0); $.box.style.top = ( real_top ) + "px"; params["top"] = Math.max(value,0); } } this.left = function(ctrl) { var _shiftX = (params["parent"] == document.body) ? document.body.scrollLeft:0; if ( ctrl == "center" ) { var _left; if (params["parent"] == document.body) { _left = ( parseInt(window.innerWidth) - parseInt($.box.style.width) ) / 2; } else { _left = ( parseInt(params["parent"].clientWidth ) - parseInt($.box.style.width) ) / 2; } $.box.style.left = ( Math.floor(_left) + _shiftX ) + "px"; if ( params["left"] != "center" ) { my._P_installEventListener(window,"resize",my._P_resize_X_callback,"window"); params["left"] = "center"; } } else { if ( params["left"] == "center" ) { my._P_deleteEventListener(window,"resize",my._P_resize_X_callback,"window"); } $.box.style.left = ( ctrl + _shiftX ) + "px"; params["left"] = ctrl; } } this.width = function(value,ctrl) { if ( value == "auto" ) { if ( params["url"] === null ) { var c2 = $.contents.firstChild; if ( c2 ) { value = parseInt(c2.style.width,10); } } else if ( $.window !== null ) { $.iframe.style.width = "100px"; var maxWidth = document.body.clientWidth; var needWidth = $.window.document.body.scrollWidth; value = Math.min(needWidth,maxWidth); } } if ( !isNaN(value) ) { if ( typeof(ctrl) == "undefined" || ctrl == true ) params["width"] = value; $.box.style.width = value + "px"; $.title.style.width = value + "px"; $.contents.style.width = value + "px"; if ( $.iframe ) $.iframe.style.width = value + "px"; if ( params["left"] == "auto" ) { my.left("auto"); } if ( params["resizable"] === true ) { $.rightBorder.style.left = value + "px"; $.bottomBorder.style.width = ( value - 25 ) + "px"; $.rbBorder.style.left = value + "px"; $.brBorder.style.left = ( value - 25 ) + "px"; } } else { } } this.height = function(value,ctrl) { if ( value == "auto" ) { if ( params["url"] === null ) { var c2 = $.contents.firstChild; if ( c2 ) { value = parseInt(c2.style.height,10); } } else if ( $.window !== null ) { $.iframe.style.height = "100px"; var maxHeight = document.body.clientHeight - 50; var needHeight = $.window.document.body.scrollHeight; if ($GLOBALS["system_key"] == "pc") { value = Math.min(needHeight,maxHeight); } else { value = needHeight; } } } if ( !isNaN(value) ) { params["height"] = value; var h_out, h_in; if ( typeof(ctrl) == "undefined" || ctrl === true ) { h_out = value + 25; h_in = value; } else { h_out = value; h_in = value - 25; } $.box.style.height = h_out + "px"; $.contents.style.height = h_in + "px"; if ( $.iframe ) $.iframe.style.height = h_in + "px"; if ( params["resizable"] == true ) { $.rightBorder.style.height = ( h_in - 25 ) + "px"; $.bottomBorder.style.top = h_out + "px"; $.rbBorder.style.top = h_in + "px"; $.brBorder.style.top = h_out + "px"; } } } this.title = function(text) { while ( $.title.childNodes.length > 1 ) { $.title.removeChild($.title.lastChild); } var $_text = document.createTextNode(String.fromCharCode(160,160)+text); $.title.appendChild($_text); } this.id = function(text) { $.box.id = text; } this.opacity = function(value) { $.box.style.opacity = value; } this.closed = function() { return _.closed; } this.onclose = function(ctrl) { params['onclose'] = ctrl; } this.close = function(ctrl) { if ( params['onclose'] !== null ) { if (typeof(params['onclose']) == "function") { var ok = params['onclose'](); if ( typeof(ok) == "boolean" ) { if ( ok == false ) return; params['onclose'] = null; } } else { alert("710 : onclose()\n"+typeof(params['onclose'])+"\n"+params['onclose']); } } if (typeof(ctrl) == "integer") { if ( $GLOBALS["popup"][_.nr] ) { params['onclose'] = null; window.setTimeout("$GLOBALS[\"popup\"]["+_.nr+"].close();",ctrl); } } else { my._P_deleteEventListener($.close,"click",my._P_click_callback,"close"); my._P_deleteEventListener($.close,"mousedown",my._P_click_callback,"close"); my._P_deleteEventListener($.title,"mousedown",my._P_mousedown_callback,"title"); if ( params["resizable"] == true ) { my._P_deleteEventListener($.rightBorder,"mousedown",my._P_mousedown_callback,"rightBorder"); my._P_deleteEventListener($.bottomBorder,"mousedown",my._P_mousedown_callback,"bottomBorder"); my._P_deleteEventListener($.rbBorder,"mousedown",my._P_mousedown_callback,"rbBorder"); my._P_deleteEventListener($.brBorder,"mousedown",my._P_mousedown_callback,"brBorder"); } try { params["parent"].removeChild($.box); _.closed = true; popup_delete(this); } catch(e) {} if (params["exclusive"]) { if ($.inhibit !== null) { var $pi = $.inhibit.parentNode; if ($pi) $pi.removeChild($.inhibit); } } } } this.contents = function() { return $.contents; } this.display = function() { var _argv = this.display.arguments;//alert("display() "+_argv); if ( _argv.length > 0 ) { if ( _argv[0] == "fail" ) { $.box.style.visibility = "visible"; popup_open_failed = null; return; } } if ( popup_open_failed != null ) { window.clearTimeout(popup_open_failed); popup_open_failed = null; } my.width(params["width"]); my.height(params["height"]); if ( params["width"] == "auto" ) { if ($.window !== null) { var sw = $.window.document.body.scrollWidth; var cw = $.window.document.body.clientWidth; if ( 0 < ( sw - cw ) < 20 ) { my.width(sw + sw - cw); } } } if (params["depend"] != null) { if (params["depend"].getBoundingClientRect) { var rect = params["depend"].getBoundingClientRect(); console.log(rect.top, rect.right, rect.bottom, rect.left); } } var v = params["top"]; params["top"] = "init";//alert(typeof(v)); my.top(v); v = params["left"]; params["left"] = "init"; my.left(v); $.box.style.visibility = "visible"; } this.window = function(obj) { $.window = obj; } this.zindex = function(ctrl) { params["zindex"] = ctrl; var z = parseInt(ctrl); if ($.inhibit) { $.inhibit.style.zIndex = z + (_.nr * 3); } if ($.box) { $.box.style.zIndex = z + 1 + (_.nr * 3); } if ($.overlay) { $.overlay.style.zIndex = z + 2 + (_.nr * 3); } } this.init = function(ctrl) { if ( typeof(ctrl) == "undefined" ) ctrl = {}; var defaults = { parent:document.body, url:null, id:null, width:"auto", height:"auto", top:"middle", left:"center", depend:null, title:"", resizable:true, moveable:true, zindex:(100+_.nr), opacity:null, exclusive:true, inhibitClassName:null, onclose:null, boxClassName:null, titleClassName:null, contentsClassName:null, iframeClassName:null, closeClassName:null, closeImage:null }; for ( var param in defaults ) { params[param] = (typeof(ctrl[param]) != "undefined") ? ctrl[param] : defaults[param]; } my = $GLOBALS["popup"][_.nr]; if (params["exclusive"] === true) { $.inhibit = document.createElement("div"); $.inhibit.style.position = "absolute"; $.inhibit.style.top = 0; $.inhibit.style.left = 0; $.inhibit.style.height = document.body.scrollHeight + "px"; //window.innerHeight + "px"; $.inhibit.style.width = document.body.scrollWidth + "px"; //window.innerWidth + "px"; $.inhibit.style.zIndex = (parseInt(params["zindex"]) + (_.nr * 3)); if ( params["inhibitClassName"] != null ) { $.inhibit.className = params["inhibitClassName"]; } else { $.inhibit.style.backgroundColor = "rgb(255,255,255)"; $.inhibit.style.opacity = "0.8"; } document.body.appendChild($.inhibit); my._P_installEventListener(window,"resize",my._P_resize_Y_callback,"window"); my._P_installEventListener(window,"resize",my._P_resize_X_callback,"window"); } var _shiftX = (params["parent"] == document.body) ? document.body.scrollLeft:0; var _shiftY = (params["parent"] == document.body) ? document.body.scrollTop:0; $.box = document.createElement("div"); if (params["id"] != null) $.box.id = params["id"]; $.box.name = "popup_"+_.nr; $.box.style.position = "absolute"; $.box.style.display = "block"; $.box.style.width = "500px"; $.box.style.height = "400px"; $.box.style.top = (_shiftY + 50) + "px"; $.box.style.left = (_shiftX + 200) + "px"; $.box.style.zIndex = (parseInt(params["zindex"]) +1+ (_.nr * 3)); if ( params["boxClassName"] != null ) { $.box.className = params["boxClassName"]; } else { $.box.style.border = "outset 3px #AAAAAA"; // #E5E5E5 #5E5E5E 94 -> 170 -> 229 ( -76 +59 ) } if ( params["opacity"] != null ) { $.box.style.opacity = params["opacity"]; } $.title = document.createElement("div"); $.title.style.display = "block"; $.title.style.width = "500px"; $.title.style.height = "25px"; $.title.style.overflow = "hidden"; $.title.style.lineHeight = "25px"; $.title.style.fontWeight = "bold"; if (params["titleClassName"] != null) { $.title.className = params["titleClassName"]; } else { $.title.style.backgroundColor = "#888888"; $.title.style.color = "#FFFFFF"; $.title.style.cursor = "move"; } $.box.appendChild($.title); $.close = document.createElement("div"); $.close.style.display = "block"; $.close.style.cssFloat = "right"; $.close.style.width = "25px"; $.close.style.height = "25px"; var defaultImage = { src:"data:image/gif;base64, R0lGODlhGQAZANc+AP///+BXNOA4AuFWLudvUt5SL+VMGeJNJORTJeQ+B+VDDd9VM+BQKd1MKOVpS/9QKOdnQeVIE+h0W+JYNuRiQttDHNg3DgAAAOh8YuNcOgAAAONMHOdkO99TMOuKceNbOgAAAOZEDQAAAOhiNQAAAOdyWeh6YOyReeJLIudwVAAAAOZsTepeLQAAAOVnSeZoRehwVeRfQelKEQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAPbMwgAAAGaQ5gAAAPO6rAAAAAAAAAAAAOdVJgAAAAAAAN9FHkAAAIAAAKAAAMAAAOAAAP8AAABAAEBAAIBAAKBAAMBAAOBAAP9AAACAAECAAICAAKCAAMCAAOCAAP+AAACgAECgAICgAKCgAMCgAOCgAP+gAADAAEDAAIDAAKDAAMDAAODAAP/AAADgAEDgAIDgAKDgAMDgAODgAP/gAAD/AED/AID/AKD/AMD/AOD/AP//AAAAQEAAQIAAQKAAQMAAQOAAQP8AQABAQEBAQIBAQKBAQMBAQOBAQP9AQACAQECAQICAQKCAQMCAQOCAQP+AQACgQECgQICgQKCgQMCgQOCgQP+gQADAQEDAQIDAQKDAQMDAQODAQP/AQADgQEDgQIDgQKDgQMDgQODgQP/gQAD/QED/QID/QKD/QMD/QOD/QP//QAAAgEAAgIAAgKAAgMAAgOAAgP8AgABAgEBAgIBAgKBAgMBAgOBAgP9AgACAgECAgICAgKCAgMCAgOCAgP+AgACggECggICggKCggMCggOCggP+ggADAgEDAgIDAgKDAgMDAgODAgP/AgADggEDggIDggKDggMDggODggP/ggAD/gED/gID/gKD/gMD/gOD/gP//gAAAwEAAwIAAwKAAwMAAwOAAwP8AwABAwEBAwIBAwKBAwMBAwOBAwP9AwACAwECAwICAwKCAwMCAwOCAwP+AwACgwECgwICgwKCgwMCgwOCgwP+gwADAwEDAwIDAwKDAwMDAwODAwP/AwADgwCH5BAEAAPgALAAAAAAZABkAAAiZAPEJHEiwoMGDCBMqXMjQh8OHECNCNCixYkQqFH082Mixo0cqGAs69EiyI8iMG30AKAlAyMaTIjU+AEDTI82VD2ASHLnxJkefL0PulNmzJtCgKDverGlS6ECeSpk2Tfpz6UenAqHONCo1J1Z8UI8e1flU5tGiOMlmlamSpUuvVEtejSuXo1qwIPPq3avXIN+/fBkKHky4MMKAADs=", alt:"schließen", title:"close", style:{cursor:"pointer"} }; if ( params["closeClassName"] !== null ) { $.close.className = params["closeClassName"]; if ( params["closeImage"] != null ) { var img = document.createElement("img"); var cip = params["closeImage"]; for ( var param in defaultImage ) { if ( param != "style" ) { defaultImage[param] = (cip[param]) ? cip[param] : defaultImage[param]; } if ( defaultImage[param] != null ) { if ( param != "style" ) { img[param] = defaultImage[param]; } else { if ( typeof(cip[param]) == "undefined" ) cip[param] = {}; for ( var styleParam in defaultImage[param] ) { defaultImage[param][styleParam] = (cip[param][styleParam]) ? cip[param][styleParam] : defaultImage[param][styleParam]; if ( defaultImage[param][styleParam] != null ) { img.style[styleParam] = defaultImage[param][styleParam]; } } } } } $.close.appendChild(img); } } else { var img = document.createElement("img"); img.src = defaultImage["src"]; img.alt = defaultImage["alt"]; img.title = defaultImage["title"]; img.style.cursor = "pointer"; $.close.appendChild(img); } $.title.appendChild($.close); var headline = document.createTextNode(String.fromCharCode(160,160) + params["title"]); $.title.appendChild(headline); $.contents = document.createElement("div"); $.contents.style.display = "block"; $.contents.style.cssClear = "both"; $.contents.style.position = "relative"; $.contents.style.width = "490px"; $.contents.style.height = "375px"; if ( params["contentsClassName"] != null ) { $.contents.className = params["contentsClassName"]; } else { $.contents.style.backgroundColor = "#FFFFFF"; } $.box.appendChild($.contents); if ( params["resizable"] == true ) { $.rightBorder = document.createElement("div"); $.rightBorder.style.display = "block"; $.rightBorder.style.position = "absolute"; $.rightBorder.style.top = "25px"; $.rightBorder.style.left = "497px"; // 500 - 3 $.rightBorder.style.width = "3px"; $.rightBorder.style.height = "350px"; // 400 - 25 - 25 $.rightBorder.style.backgroundColor = "rgb(0,0,0)"; $.rightBorder.style.opacity = "0.01"; $.rightBorder.style.cursor = "e-resize"; $.box.appendChild($.rightBorder); $.bottomBorder = document.createElement("div"); $.bottomBorder.style.display = "block"; $.bottomBorder.style.position = "absolute"; $.bottomBorder.style.top = "397px"; // 400 - 3 $.bottomBorder.style.height = "3px"; $.bottomBorder.style.width = "475px"; // 500 - 25 $.bottomBorder.style.left = "0px"; $.bottomBorder.style.backgroundColor = "rgb(0,0,0)"; $.bottomBorder.style.opacity = "0.01"; $.bottomBorder.style.cursor = "n-resize"; $.box.appendChild($.bottomBorder); $.rbBorder = document.createElement("div"); $.rbBorder.style.position = "absolute"; $.rbBorder.style.display = "block"; $.rbBorder.style.left = "497px"; // 500 - 3 $.rbBorder.style.top = "375px"; // 400 - 25 $.rbBorder.style.width = "3px"; $.rbBorder.style.height = "26px"; $.rbBorder.style.backgroundColor = "rgb(0,0,0)"; $.rbBorder.style.opacity = "0.01"; $.rbBorder.style.cursor = "se-resize"; $.box.appendChild($.rbBorder); $.brBorder = document.createElement("div"); $.brBorder.style.position = "absolute"; $.brBorder.style.display = "block"; $.brBorder.style.left = "475px"; // 500 - 25 $.brBorder.style.top = "397px"; // 400 - 3 $.brBorder.style.width = "26px"; $.brBorder.style.height = "3px"; $.brBorder.style.backgroundColor = "rgb(0,0,0)"; $.brBorder.style.opacity = "0.01"; $.brBorder.style.cursor = "se-resize"; $.box.appendChild($.brBorder); } $.box.style.visibility = "hidden"; params["parent"].appendChild($.box); _.closed = false; my._P_installEventListener($.close,"click",my._P_click_callback,"close"); my._P_installEventListener($.close,"mousedown",my._P_click_callback,"close"); if ( params["moveable"] == true ) { my._P_installEventListener($.title,"mousedown",my._P_mousedown_callback,"title"); } if ( params["resizable"] == true ) { my._P_installEventListener($.rightBorder,"mousedown",my._P_mousedown_callback,"rightBorder"); my._P_installEventListener($.bottomBorder,"mousedown",my._P_mousedown_callback,"bottomBorder"); my._P_installEventListener($.rbBorder,"mousedown",my._P_mousedown_callback,"rbBorder"); my._P_installEventListener($.brBorder,"mousedown",my._P_mousedown_callback,"brBorder"); } if ( params["url"] != null ) { $.iframe = document.createElement("iframe"); $.iframe.onload = my._P_onload; $.iframe.frameBorder = 0; $.iframe.style.width = "500px"; $.iframe.style.height = "375px"; $.iframe.name="iframe_"+_.nr; $.iframe.src = params["url"]; if (params["iframeClassName"] != null) $.iframe.className = params["iframeClassName"]; $.contents.appendChild($.iframe); } $.box.style.visibility = "hidden"; popup_open_failed = window.setTimeout("popup_open("+_.nr+",'fail')",10000); var z = _.nr + 103; $GLOBALS["zmax"] = ( z > $GLOBALS["zmax"] ) ? z : $GLOBALS["zmax"]; } }