// Licensed Materials - Property of IBM // // IBM Cognos Products: pps // // (C) Copyright IBM Corp. 2005, 2017 // // US Government Users Restricted Rights - Use, duplication or disclosure restricted by GSA ADP Schedule Contract with IBM Corp. function eventManager(event) { // Member variables this.theEvent = event; if (!this.theEvent) this.theEvent = window.event; // Methods this.cancelBubble = function() { this.theEvent.cancelBubble = true; this.theEvent.returnValue = false; if (this.theEvent.stopPropagation) { this.theEvent.stopPropagation(); } } this.preventDefault = function() { if (this.theEvent.stopPropagation) { this.theEvent.preventDefault(); } } this.getSrc = function() { if (typeof this.theEvent.srcElement != "undefined") { return this.theEvent.srcElement; //IE event source } else { return this.theEvent.originalTarget; //Netscape event source } } } function doEvent (event, cmd) { var mgr = new eventManager(event); mgr.cancelBubble(); eval(cmd); } function doEventCmd (event, cmd) { var mgr = new eventManager(event); mgr.cancelBubble(); doit(cmd); } function attrib(name,value) { this.name = name; this.value = value; } var nodeMap = new Array(); var nodeMapLength = 0; var timeoutSet = false; // To compensate for Microsoft KB 269802 function insertIMGNode(container, src, className, attributes, containersDoc) { var doc = containersDoc; if (!doc) { doc = document; if (!topparent.getGlobal("nn7") && !topparent.getGlobal("safari")) doc = container.document; } var node = doc.createElement("IMG"); node.className = className; for (var i = 0; i < attributes.length; i++) { node.setAttribute(attributes[i].name,attributes[i].value); } if (topparent.getGlobal("nn7") || topparent.getGlobal("safari")) node.src = src; else setIconSrc(node,src); container.appendChild(node); return node; } function setIconSrc(node, src) { node.style.visibility = 'hidden'; storeNode(node,src); if (!timeoutSet) { timeoutSet = true; window.setTimeout("setNodeSrcs();", 1); window.setTimeout("showNodes();timeoutSet = false;", 1); } } function storeNode(node,src) { node.setAttribute("theSrc",src); nodeMap[nodeMapLength++] = node; } function setNodeSrcs() { for (var i = 0; i < nodeMapLength; i++) { nodeMap[i].src = nodeMap[i].getAttribute("theSrc"); } } function showNodes() { while (nodeMapLength) { nodeMap[nodeMapLength - 1].style.visibility = 'visible'; nodeMapLength--; } } function isLoadingImages() { return (nodeMapLength != 0); } function getPageOffsetLeft(obj) { var left = obj.offsetLeft; var oParent = obj.offsetParent; while (oParent) { left += oParent.offsetLeft; oParent = oParent.offsetParent; } return left; } function getPageOffsetTop(obj) { var top = obj.offsetTop; var oParent = obj.offsetParent; while (oParent) { top += oParent.offsetTop; oParent = oParent.offsetParent; } return top; }