git.asbjorn.biz
/
jquery.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
6728e3c
)
Added .hasClass() (Simply just passes through to .is()).
author
John Resig
<jeresig@gmail.com>
Sat, 8 Sep 2007 13:49:42 +0000
(13:49 +0000)
committer
John Resig
<jeresig@gmail.com>
Sat, 8 Sep 2007 13:49:42 +0000
(13:49 +0000)
src/core.js
patch
|
blob
|
history
diff --git
a/src/core.js
b/src/core.js
index
537b4e2
..
ab6b619
100644
(file)
--- a/
src/core.js
+++ b/
src/core.js
@@
-304,6
+304,10
@@
jQuery.fn = jQuery.prototype = {
is: function(expr) {
return expr ? jQuery.multiFilter(expr,this).length > 0 : false;
},
+
+ hasClass: function(expr) {
+ return this.is("." + expr);
+ },
val: function( val ) {
if ( val == undefined ) {