Changes between Initial Version and Version 1 of Ticket #15229, comment 4


Ignore:
Timestamp:
Apr 23, 2012, 8:19:29 PM (9 years ago)
Author:
bill
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #15229, comment 4

    initial v1  
    11It's possible to control the document used by these methods via withDoc() or withGlobal().
    22
    3 However, out of all the dom* and window methods, these were the only ones where using withDoc() was necessary'.   byId() and toDom() take a document parameter, so I followed that precedent.    Many other methods infer the document from a DOMNode parameter, but that wasn't possible for the above methods.
     3However, out of all the dom* and window methods, these were the only ones where using withDoc() was necessary.   byId() and toDom() take a document parameter, so I followed that precedent.    Many other methods infer the document from a DOMNode parameter, but that wasn't possible for the above methods.
    44
    55Besides the consistency issue, passing a document parameter to these methods is faster and less code than using withDoc().