Changeset 13066

Show
Ignore:
Timestamp:
03/13/08 04:52:43 (2 months ago)
Author:
alex
Message:

update query() to move combinator-rooted queries off to a non-querySelectorAll branch until the webapis WG decides that they're the right thing to do (which they clearly are). Refs #5832. !strict

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • dojo/trunk/_base/query.js

    r12836 r13066  
    947947        var getQueryFunc = function(query){ 
    948948                // return a cached version if one is available 
    949                 if(d.doc["querySelectorAll"]){ 
     949                var qcz = query.charAt(0); 
     950                if(d.doc["querySelectorAll"] &&  
     951                        // as per CSS 3, we can't currently start w/ combinator: 
     952                        //              http://www.w3.org/TR/css3-selectors/#w3cselgrammar 
     953                        !(qcz == ">" || qcz == "+" || qcz == "~")        
     954                ){ 
    950955                        return function(root){ 
    951956                                var r = root.querySelectorAll(query);