2013-08-15 18:15:49 +00:00
|
|
|
define([
|
|
|
|
"./core",
|
|
|
|
"./selector"
|
2013-09-02 17:21:09 +00:00
|
|
|
], function( jQuery ) {
|
2013-09-09 15:26:21 +00:00
|
|
|
|
2013-03-27 01:20:27 +00:00
|
|
|
var isSimple = /^.[^:#\[\.,]*$/,
|
2013-05-01 15:33:06 +00:00
|
|
|
rparentsprev = /^(?:parents|prev(?:Until|All))/,
|
2012-07-23 16:48:29 +00:00
|
|
|
rneedsContext = jQuery.expr.match.needsContext,
|
2011-01-14 14:55:40 +00:00
|
|
|
// methods guaranteed to produce a unique set when starting from a unique set
|
|
|
|
guaranteedUnique = {
|
|
|
|
children: true,
|
|
|
|
contents: true,
|
|
|
|
next: true,
|
|
|
|
prev: true
|
|
|
|
};
|
2010-10-10 04:33:02 +00:00
|
|
|
|
2009-03-18 21:15:38 +00:00
|
|
|
jQuery.fn.extend({
|
|
|
|
find: function( selector ) {
|
2013-04-20 14:02:07 +00:00
|
|
|
var i,
|
|
|
|
ret = [],
|
|
|
|
self = this,
|
|
|
|
len = self.length;
|
2009-03-18 21:15:38 +00:00
|
|
|
|
2011-03-16 05:16:32 +00:00
|
|
|
if ( typeof selector !== "string" ) {
|
2012-11-01 02:43:04 +00:00
|
|
|
return this.pushStack( jQuery( selector ).filter(function() {
|
2013-01-30 01:57:26 +00:00
|
|
|
for ( i = 0; i < len; i++ ) {
|
2011-03-16 05:16:32 +00:00
|
|
|
if ( jQuery.contains( self[ i ], this ) ) {
|
|
|
|
return true;
|
|
|
|
}
|
|
|
|
}
|
2012-11-01 02:43:04 +00:00
|
|
|
}) );
|
|
|
|
}
|
2009-03-18 21:15:38 +00:00
|
|
|
|
2013-01-30 01:57:26 +00:00
|
|
|
for ( i = 0; i < len; i++ ) {
|
2013-04-20 14:02:07 +00:00
|
|
|
jQuery.find( selector, self[ i ], ret );
|
2009-03-18 21:15:38 +00:00
|
|
|
}
|
|
|
|
|
2012-10-30 17:32:53 +00:00
|
|
|
// Needed because $( selector, context ) becomes $( context ).find( selector )
|
2013-01-30 01:57:26 +00:00
|
|
|
ret = this.pushStack( len > 1 ? jQuery.unique( ret ) : ret );
|
2013-04-20 14:02:07 +00:00
|
|
|
ret.selector = this.selector ? this.selector + " " + selector : selector;
|
2012-11-02 01:40:01 +00:00
|
|
|
return ret;
|
2009-03-18 21:15:38 +00:00
|
|
|
},
|
|
|
|
|
2009-12-09 20:43:13 +00:00
|
|
|
has: function( target ) {
|
2012-07-27 22:19:01 +00:00
|
|
|
var i,
|
2012-07-10 01:38:11 +00:00
|
|
|
targets = jQuery( target, this ),
|
2012-07-27 22:19:01 +00:00
|
|
|
len = targets.length;
|
2012-07-10 01:38:11 +00:00
|
|
|
|
2009-12-09 20:43:13 +00:00
|
|
|
return this.filter(function() {
|
2012-07-27 22:19:01 +00:00
|
|
|
for ( i = 0; i < len; i++ ) {
|
2009-12-09 20:43:13 +00:00
|
|
|
if ( jQuery.contains( this, targets[i] ) ) {
|
|
|
|
return true;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
});
|
|
|
|
},
|
|
|
|
|
2009-07-16 07:32:11 +00:00
|
|
|
not: function( selector ) {
|
2013-03-27 01:20:27 +00:00
|
|
|
return this.pushStack( winnow(this, selector || [], true) );
|
2009-07-16 07:32:11 +00:00
|
|
|
},
|
|
|
|
|
2009-03-18 21:15:38 +00:00
|
|
|
filter: function( selector ) {
|
2013-03-27 01:20:27 +00:00
|
|
|
return this.pushStack( winnow(this, selector || [], false) );
|
2009-03-18 21:15:38 +00:00
|
|
|
},
|
2010-12-30 06:34:48 +00:00
|
|
|
|
2009-12-10 17:25:25 +00:00
|
|
|
is: function( selector ) {
|
2013-04-20 15:40:27 +00:00
|
|
|
return !!winnow(
|
|
|
|
this,
|
|
|
|
|
|
|
|
// If this is a positional/relative selector, check membership in the returned set
|
|
|
|
// so $("p:first").is("p:last") won't return true for a doc with two "p".
|
|
|
|
typeof selector === "string" && rneedsContext.test( selector ) ?
|
|
|
|
jQuery( selector ) :
|
|
|
|
selector || [],
|
|
|
|
false
|
|
|
|
).length;
|
2009-12-10 17:25:25 +00:00
|
|
|
},
|
2009-03-18 21:15:38 +00:00
|
|
|
|
2009-12-03 00:05:51 +00:00
|
|
|
closest: function( selectors, context ) {
|
2012-07-10 01:38:11 +00:00
|
|
|
var cur,
|
|
|
|
i = 0,
|
|
|
|
l = this.length,
|
|
|
|
ret = [],
|
2012-07-23 16:48:29 +00:00
|
|
|
pos = rneedsContext.test( selectors ) || typeof selectors !== "string" ?
|
2011-03-22 00:59:20 +00:00
|
|
|
jQuery( selectors, context || this.context ) :
|
|
|
|
0;
|
2010-09-28 00:59:42 +00:00
|
|
|
|
2012-07-10 01:38:11 +00:00
|
|
|
for ( ; i < l; i++ ) {
|
2013-01-27 16:36:04 +00:00
|
|
|
for ( cur = this[i]; cur && cur !== context; cur = cur.parentNode ) {
|
|
|
|
// Always skip document fragments
|
|
|
|
if ( cur.nodeType < 11 && (pos ?
|
|
|
|
pos.index(cur) > -1 :
|
2010-10-10 04:33:02 +00:00
|
|
|
|
2013-01-27 16:36:04 +00:00
|
|
|
// Don't pass non-elements to Sizzle
|
|
|
|
cur.nodeType === 1 &&
|
|
|
|
jQuery.find.matchesSelector(cur, selectors)) ) {
|
|
|
|
|
|
|
|
cur = ret.push( cur );
|
2010-10-10 17:37:36 +00:00
|
|
|
break;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
2010-09-28 00:59:42 +00:00
|
|
|
|
2012-11-02 00:36:48 +00:00
|
|
|
return this.pushStack( ret.length > 1 ? jQuery.unique( ret ) : ret );
|
2009-03-18 21:15:38 +00:00
|
|
|
},
|
2010-12-30 06:34:48 +00:00
|
|
|
|
2009-12-10 17:25:25 +00:00
|
|
|
// Determine the position of an element within
|
|
|
|
// the matched set of elements
|
|
|
|
index: function( elem ) {
|
2011-06-15 04:38:36 +00:00
|
|
|
|
|
|
|
// No argument, return index in parent
|
|
|
|
if ( !elem ) {
|
2012-10-16 14:25:08 +00:00
|
|
|
return ( this[0] && this[0].parentNode ) ? this.first().prevAll().length : -1;
|
2011-06-15 04:38:36 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
// index in selector
|
|
|
|
if ( typeof elem === "string" ) {
|
|
|
|
return jQuery.inArray( this[0], jQuery( elem ) );
|
2009-12-10 17:25:25 +00:00
|
|
|
}
|
2011-06-15 04:38:36 +00:00
|
|
|
|
2009-12-10 17:25:25 +00:00
|
|
|
// Locate the position of the desired element
|
|
|
|
return jQuery.inArray(
|
|
|
|
// If it receives a jQuery object, the first element is used
|
|
|
|
elem.jquery ? elem[0] : elem, this );
|
|
|
|
},
|
2009-03-18 21:15:38 +00:00
|
|
|
|
2009-11-07 15:43:31 +00:00
|
|
|
add: function( selector, context ) {
|
A follow-up to [6578] (which stopped adding expandos to elements that didn't have data). That broke jQuery.unique() (so we're now using the unique from Sizzle). Using Sizzle's unique (which also sorts in document order) changed how add, andSelf, parents, nextAll, prevAll, and siblings work. after and before were changed to not use .add() (in order to guarantee their position in the jQuery set). Also, jQuery.data(elem) was updated to return that element's data object (instead of its ID).
$("<div/>").after("<span/>")
=> [ div, span ]
(calling after on a disconnected DOM node adds the nodes to the end of the jQuery set)
$("<div/>").before("<span/>")
=> [ span, div ]
(calling before on a disconnected DOM node adds the nodes to the beginning of the jQuery set)
$("div").add("span")
=> [ div, span, span, div, span ]
(results now come out in document order)
$("div").find("code").andSelf();
=> [ div, code, code ]
(results now come out in document order)
Same goes for .parents(), .nextAll(), .prevAll(), and .siblings().
Exception: .parents() will still return the results in reverse document order.
jQuery.data(elem)
=> { object of data }
(no longer returns the unique ID assigned to the node)
2009-09-25 17:55:20 +00:00
|
|
|
var set = typeof selector === "string" ?
|
2010-12-29 02:07:04 +00:00
|
|
|
jQuery( selector, context ) :
|
2011-04-17 17:51:24 +00:00
|
|
|
jQuery.makeArray( selector && selector.nodeType ? [ selector ] : selector ),
|
A follow-up to [6578] (which stopped adding expandos to elements that didn't have data). That broke jQuery.unique() (so we're now using the unique from Sizzle). Using Sizzle's unique (which also sorts in document order) changed how add, andSelf, parents, nextAll, prevAll, and siblings work. after and before were changed to not use .add() (in order to guarantee their position in the jQuery set). Also, jQuery.data(elem) was updated to return that element's data object (instead of its ID).
$("<div/>").after("<span/>")
=> [ div, span ]
(calling after on a disconnected DOM node adds the nodes to the end of the jQuery set)
$("<div/>").before("<span/>")
=> [ span, div ]
(calling before on a disconnected DOM node adds the nodes to the beginning of the jQuery set)
$("div").add("span")
=> [ div, span, span, div, span ]
(results now come out in document order)
$("div").find("code").andSelf();
=> [ div, code, code ]
(results now come out in document order)
Same goes for .parents(), .nextAll(), .prevAll(), and .siblings().
Exception: .parents() will still return the results in reverse document order.
jQuery.data(elem)
=> { object of data }
(no longer returns the unique ID assigned to the node)
2009-09-25 17:55:20 +00:00
|
|
|
all = jQuery.merge( this.get(), set );
|
|
|
|
|
2012-10-16 15:52:48 +00:00
|
|
|
return this.pushStack( jQuery.unique(all) );
|
2009-03-18 21:15:38 +00:00
|
|
|
},
|
|
|
|
|
2012-05-29 16:04:27 +00:00
|
|
|
addBack: function( selector ) {
|
2012-05-31 22:15:57 +00:00
|
|
|
return this.add( selector == null ?
|
2012-06-03 14:42:24 +00:00
|
|
|
this.prevObject : this.prevObject.filter(selector)
|
|
|
|
);
|
2009-03-18 21:15:38 +00:00
|
|
|
}
|
|
|
|
});
|
|
|
|
|
2012-05-07 20:38:55 +00:00
|
|
|
function sibling( cur, dir ) {
|
2012-05-07 20:49:23 +00:00
|
|
|
do {
|
2012-05-07 20:45:22 +00:00
|
|
|
cur = cur[ dir ];
|
2012-06-26 21:08:49 +00:00
|
|
|
} while ( cur && cur.nodeType !== 1 );
|
2012-05-07 20:49:23 +00:00
|
|
|
|
2012-05-07 20:05:05 +00:00
|
|
|
return cur;
|
|
|
|
}
|
|
|
|
|
2009-03-18 21:15:38 +00:00
|
|
|
jQuery.each({
|
2009-12-22 00:58:13 +00:00
|
|
|
parent: function( elem ) {
|
|
|
|
var parent = elem.parentNode;
|
|
|
|
return parent && parent.nodeType !== 11 ? parent : null;
|
|
|
|
},
|
|
|
|
parents: function( elem ) {
|
|
|
|
return jQuery.dir( elem, "parentNode" );
|
|
|
|
},
|
|
|
|
parentsUntil: function( elem, i, until ) {
|
|
|
|
return jQuery.dir( elem, "parentNode", until );
|
|
|
|
},
|
|
|
|
next: function( elem ) {
|
2012-05-07 20:38:55 +00:00
|
|
|
return sibling( elem, "nextSibling" );
|
2009-12-22 00:58:13 +00:00
|
|
|
},
|
|
|
|
prev: function( elem ) {
|
2012-05-07 20:38:55 +00:00
|
|
|
return sibling( elem, "previousSibling" );
|
2009-12-22 00:58:13 +00:00
|
|
|
},
|
|
|
|
nextAll: function( elem ) {
|
|
|
|
return jQuery.dir( elem, "nextSibling" );
|
|
|
|
},
|
|
|
|
prevAll: function( elem ) {
|
|
|
|
return jQuery.dir( elem, "previousSibling" );
|
|
|
|
},
|
|
|
|
nextUntil: function( elem, i, until ) {
|
|
|
|
return jQuery.dir( elem, "nextSibling", until );
|
|
|
|
},
|
|
|
|
prevUntil: function( elem, i, until ) {
|
|
|
|
return jQuery.dir( elem, "previousSibling", until );
|
|
|
|
},
|
|
|
|
siblings: function( elem ) {
|
2012-02-22 05:21:18 +00:00
|
|
|
return jQuery.sibling( ( elem.parentNode || {} ).firstChild, elem );
|
2009-12-22 00:58:13 +00:00
|
|
|
},
|
|
|
|
children: function( elem ) {
|
|
|
|
return jQuery.sibling( elem.firstChild );
|
|
|
|
},
|
|
|
|
contents: function( elem ) {
|
|
|
|
return jQuery.nodeName( elem, "iframe" ) ?
|
|
|
|
elem.contentDocument || elem.contentWindow.document :
|
2012-06-28 00:55:36 +00:00
|
|
|
jQuery.merge( [], elem.childNodes );
|
2009-12-22 00:58:13 +00:00
|
|
|
}
|
|
|
|
}, function( name, fn ) {
|
2009-12-04 17:28:47 +00:00
|
|
|
jQuery.fn[ name ] = function( until, selector ) {
|
2011-11-06 21:38:26 +00:00
|
|
|
var ret = jQuery.map( this, fn, until );
|
2010-12-30 06:34:48 +00:00
|
|
|
|
2013-03-27 01:20:27 +00:00
|
|
|
if ( name.slice( -5 ) !== "Until" ) {
|
2009-12-04 17:28:47 +00:00
|
|
|
selector = until;
|
|
|
|
}
|
2009-03-18 21:15:38 +00:00
|
|
|
|
A follow-up to [6578] (which stopped adding expandos to elements that didn't have data). That broke jQuery.unique() (so we're now using the unique from Sizzle). Using Sizzle's unique (which also sorts in document order) changed how add, andSelf, parents, nextAll, prevAll, and siblings work. after and before were changed to not use .add() (in order to guarantee their position in the jQuery set). Also, jQuery.data(elem) was updated to return that element's data object (instead of its ID).
$("<div/>").after("<span/>")
=> [ div, span ]
(calling after on a disconnected DOM node adds the nodes to the end of the jQuery set)
$("<div/>").before("<span/>")
=> [ span, div ]
(calling before on a disconnected DOM node adds the nodes to the beginning of the jQuery set)
$("div").add("span")
=> [ div, span, span, div, span ]
(results now come out in document order)
$("div").find("code").andSelf();
=> [ div, code, code ]
(results now come out in document order)
Same goes for .parents(), .nextAll(), .prevAll(), and .siblings().
Exception: .parents() will still return the results in reverse document order.
jQuery.data(elem)
=> { object of data }
(no longer returns the unique ID assigned to the node)
2009-09-25 17:55:20 +00:00
|
|
|
if ( selector && typeof selector === "string" ) {
|
2009-10-26 22:07:57 +00:00
|
|
|
ret = jQuery.filter( selector, ret );
|
A follow-up to [6578] (which stopped adding expandos to elements that didn't have data). That broke jQuery.unique() (so we're now using the unique from Sizzle). Using Sizzle's unique (which also sorts in document order) changed how add, andSelf, parents, nextAll, prevAll, and siblings work. after and before were changed to not use .add() (in order to guarantee their position in the jQuery set). Also, jQuery.data(elem) was updated to return that element's data object (instead of its ID).
$("<div/>").after("<span/>")
=> [ div, span ]
(calling after on a disconnected DOM node adds the nodes to the end of the jQuery set)
$("<div/>").before("<span/>")
=> [ span, div ]
(calling before on a disconnected DOM node adds the nodes to the beginning of the jQuery set)
$("div").add("span")
=> [ div, span, span, div, span ]
(results now come out in document order)
$("div").find("code").andSelf();
=> [ div, code, code ]
(results now come out in document order)
Same goes for .parents(), .nextAll(), .prevAll(), and .siblings().
Exception: .parents() will still return the results in reverse document order.
jQuery.data(elem)
=> { object of data }
(no longer returns the unique ID assigned to the node)
2009-09-25 17:55:20 +00:00
|
|
|
}
|
|
|
|
|
2013-03-27 01:20:27 +00:00
|
|
|
if ( this.length > 1 ) {
|
|
|
|
// Remove duplicates
|
|
|
|
if ( !guaranteedUnique[ name ] ) {
|
|
|
|
ret = jQuery.unique( ret );
|
|
|
|
}
|
A follow-up to [6578] (which stopped adding expandos to elements that didn't have data). That broke jQuery.unique() (so we're now using the unique from Sizzle). Using Sizzle's unique (which also sorts in document order) changed how add, andSelf, parents, nextAll, prevAll, and siblings work. after and before were changed to not use .add() (in order to guarantee their position in the jQuery set). Also, jQuery.data(elem) was updated to return that element's data object (instead of its ID).
$("<div/>").after("<span/>")
=> [ div, span ]
(calling after on a disconnected DOM node adds the nodes to the end of the jQuery set)
$("<div/>").before("<span/>")
=> [ span, div ]
(calling before on a disconnected DOM node adds the nodes to the beginning of the jQuery set)
$("div").add("span")
=> [ div, span, span, div, span ]
(results now come out in document order)
$("div").find("code").andSelf();
=> [ div, code, code ]
(results now come out in document order)
Same goes for .parents(), .nextAll(), .prevAll(), and .siblings().
Exception: .parents() will still return the results in reverse document order.
jQuery.data(elem)
=> { object of data }
(no longer returns the unique ID assigned to the node)
2009-09-25 17:55:20 +00:00
|
|
|
|
2013-05-01 15:33:06 +00:00
|
|
|
// Reverse order for parents* and prev-derivatives
|
|
|
|
if ( rparentsprev.test( name ) ) {
|
2013-03-27 01:20:27 +00:00
|
|
|
ret = ret.reverse();
|
|
|
|
}
|
A follow-up to [6578] (which stopped adding expandos to elements that didn't have data). That broke jQuery.unique() (so we're now using the unique from Sizzle). Using Sizzle's unique (which also sorts in document order) changed how add, andSelf, parents, nextAll, prevAll, and siblings work. after and before were changed to not use .add() (in order to guarantee their position in the jQuery set). Also, jQuery.data(elem) was updated to return that element's data object (instead of its ID).
$("<div/>").after("<span/>")
=> [ div, span ]
(calling after on a disconnected DOM node adds the nodes to the end of the jQuery set)
$("<div/>").before("<span/>")
=> [ span, div ]
(calling before on a disconnected DOM node adds the nodes to the beginning of the jQuery set)
$("div").add("span")
=> [ div, span, span, div, span ]
(results now come out in document order)
$("div").find("code").andSelf();
=> [ div, code, code ]
(results now come out in document order)
Same goes for .parents(), .nextAll(), .prevAll(), and .siblings().
Exception: .parents() will still return the results in reverse document order.
jQuery.data(elem)
=> { object of data }
(no longer returns the unique ID assigned to the node)
2009-09-25 17:55:20 +00:00
|
|
|
}
|
2009-03-18 21:15:38 +00:00
|
|
|
|
2012-10-24 00:22:34 +00:00
|
|
|
return this.pushStack( ret );
|
2009-03-18 21:15:38 +00:00
|
|
|
};
|
2009-07-25 21:31:59 +00:00
|
|
|
});
|
2009-10-26 22:07:57 +00:00
|
|
|
|
|
|
|
jQuery.extend({
|
|
|
|
filter: function( expr, elems, not ) {
|
2013-03-27 01:20:27 +00:00
|
|
|
var elem = elems[ 0 ];
|
|
|
|
|
2009-10-26 22:07:57 +00:00
|
|
|
if ( not ) {
|
|
|
|
expr = ":not(" + expr + ")";
|
|
|
|
}
|
|
|
|
|
2013-03-27 01:20:27 +00:00
|
|
|
return elems.length === 1 && elem.nodeType === 1 ?
|
|
|
|
jQuery.find.matchesSelector( elem, expr ) ? [ elem ] : [] :
|
|
|
|
jQuery.find.matches( expr, jQuery.grep( elems, function( elem ) {
|
|
|
|
return elem.nodeType === 1;
|
|
|
|
}));
|
2009-10-26 22:07:57 +00:00
|
|
|
},
|
2010-12-30 06:34:48 +00:00
|
|
|
|
2009-12-04 17:28:47 +00:00
|
|
|
dir: function( elem, dir, until ) {
|
2010-11-09 16:09:07 +00:00
|
|
|
var matched = [],
|
|
|
|
cur = elem[ dir ];
|
|
|
|
|
2010-01-21 01:10:34 +00:00
|
|
|
while ( cur && cur.nodeType !== 9 && (until === undefined || cur.nodeType !== 1 || !jQuery( cur ).is( until )) ) {
|
2009-10-26 22:07:57 +00:00
|
|
|
if ( cur.nodeType === 1 ) {
|
|
|
|
matched.push( cur );
|
|
|
|
}
|
|
|
|
cur = cur[dir];
|
|
|
|
}
|
|
|
|
return matched;
|
|
|
|
},
|
|
|
|
|
|
|
|
sibling: function( n, elem ) {
|
|
|
|
var r = [];
|
|
|
|
|
|
|
|
for ( ; n; n = n.nextSibling ) {
|
|
|
|
if ( n.nodeType === 1 && n !== elem ) {
|
|
|
|
r.push( n );
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
return r;
|
|
|
|
}
|
2009-11-07 15:43:31 +00:00
|
|
|
});
|
2010-03-23 16:12:16 +00:00
|
|
|
|
|
|
|
// Implement the identical functionality for filter and not
|
2013-03-27 01:20:27 +00:00
|
|
|
function winnow( elements, qualifier, not ) {
|
2010-03-23 16:12:16 +00:00
|
|
|
if ( jQuery.isFunction( qualifier ) ) {
|
2013-03-27 01:20:27 +00:00
|
|
|
return jQuery.grep( elements, function( elem, i ) {
|
2013-04-07 03:48:48 +00:00
|
|
|
/* jshint -W018 */
|
|
|
|
return !!qualifier.call( elem, i, elem ) !== not;
|
2010-03-23 16:12:16 +00:00
|
|
|
});
|
|
|
|
|
2013-04-05 05:16:32 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
if ( qualifier.nodeType ) {
|
2013-03-27 01:20:27 +00:00
|
|
|
return jQuery.grep( elements, function( elem ) {
|
|
|
|
return ( elem === qualifier ) !== not;
|
2010-03-23 16:12:16 +00:00
|
|
|
});
|
|
|
|
|
2013-04-05 05:16:32 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
if ( typeof qualifier === "string" ) {
|
2010-03-23 16:12:16 +00:00
|
|
|
if ( isSimple.test( qualifier ) ) {
|
2013-03-27 01:20:27 +00:00
|
|
|
return jQuery.filter( qualifier, elements, not );
|
2010-03-23 16:12:16 +00:00
|
|
|
}
|
2013-04-05 05:16:32 +00:00
|
|
|
|
|
|
|
qualifier = jQuery.filter( qualifier, elements );
|
2010-03-23 16:12:16 +00:00
|
|
|
}
|
|
|
|
|
2013-04-05 05:16:32 +00:00
|
|
|
return jQuery.grep( elements, function( elem ) {
|
2013-03-27 01:20:27 +00:00
|
|
|
return ( jQuery.inArray( elem, qualifier ) >= 0 ) !== not;
|
2010-03-23 16:12:16 +00:00
|
|
|
});
|
2010-03-31 18:36:24 +00:00
|
|
|
}
|
2013-09-09 01:25:27 +00:00
|
|
|
|
|
|
|
return jQuery;
|
2013-08-15 18:15:49 +00:00
|
|
|
});
|