Netscape 6, Part VII: Object-Oriented DOCJSLIB 3.1: IE 4.x Subclass Object Listing - Doc JavaScript | WebReference

Netscape 6, Part VII: Object-Oriented DOCJSLIB 3.1: IE 4.x Subclass Object Listing - Doc JavaScript


Netscape 6, Part VII: Object-Oriented DOCJSLIB 3.1

IE 4.x Subclass Object Listing

<!--
function docjslibIE4SubClass() {
  this.inheritFrom = docjslibSuperClass;
  this.inheritFrom();
  
  this.getSrc = getSrcMethod;
  this.setSrc = setSrcMethod;
  this.setPosFromLeft = setPosFromLeftMethod;
  this.setPosFromTop = setPosFromTopMethod;
  this.setZposition = setZpositionMethod;
  this.setVisibility = setVisibilityMethod;
  this.doThisCommandEveryIntervalMS = doThisCommandEveryIntervalMSMethod;
  this.getWindowWidth = getWindowWidthMethod;
  this.getWindowHeight = getWindowHeightMethod;
  this.getPageScrollLeft = getPageScrollLeftMethod;
  this.getPageScrollTop = getPageScrollTopMethod;
  this.findHighestZ = findHighestZMethod;
  function getSrcMethod(id) {
    return eval("document.all." + id + "img.src");
  }
  
  function setSrcMethod(id, url) {
    eval("document.all." + id).src = url;
  }
  
  function setPosFromLeftMethod(id, xCoord) {
    eval("document.all." + id).style.left = xCoord;
  }
  
  function setPosFromTopMethod(id, yCoord) {
    eval("document.all." + id).style.top = yCoord;
  }
  function setZpositionMethod(id, z) {
    eval("document.all." + id).style.zIndex = z;
  }
  function setVisibilityMethod(id, flag) {
    var str = (flag) ? 'visible' : 'hidden';
    eval("document.all." + id).style.visibility = str;
  }
  
  function doThisCommandEveryIntervalMSMethod(command, interval) {
    setInterval(eval('"' + command + '"'), interval);
  }
  function getWindowWidthMethod() {
    return document.body.clientWidth;
  }
  function getWindowHeightMethod() {
    return document.body.clientHeight;
  }
  function getPageScrollLeftMethod() {
    return document.body.scrollLeft;
  }
  function getPageScrollTopMethod() {
    return document.body.scrollTop;
  }
  
  function findHighestZMethod() {
    var documentDivs = new Array();
    documentDivs = document.all.tags("DIV");
    var highestZ = 0;
    for (var i = 0; i < documentDivs.length; i++) {
      var zIndex = documentDivs[i].style.zIndex;
      highestZ = (zIndex > highestZ) ? zIndex : highestZ;
    }
    return highestZ;
  }
}
// -->

Next: Netscapce Navigator 4.x subclass object listing

https://www.internet.com


Produced by Yehuda Shiran and Tomer Shiran
All Rights Reserved. Legal Notices.
Created: February 26, 2001
Revised: February 26, 2001

URL: https://www.webreference.com/js/column78/10.html