Women in Technology

Hear us Roar



Article:
  Cross-Browser Style Objects
Subject:   Flatten Layers Tree Instead of Searching It
Date:   2002-02-01 22:54:03
From:   mszlazak
How about "flattening" the "layers tree" by referencing its layers with an associative array.
Then it would be like the document.all[] or document.getElementById() arrays and repeated tree reversals wouldn't be needed. After all, the worst case senerio for getting one layers reference is to traverse the entire tree. Multiple layers with the same id would be required an added dimension or property or just not allowed.