Issue 2589 fixed. :radio :checkbox - .checked class added.

git-svn-id: http://xe-core.googlecode.com/svn/branches/maserati@11739 201d5d3c-b55e-5fd7-737f-ddc643e51545
This commit is contained in:
ChanMyeong 2012-10-16 09:17:07 +00:00
parent 87d8a52397
commit 618180b4f6
4 changed files with 22 additions and 6 deletions

View file

@ -178,6 +178,14 @@ jQuery(function($){
$this.attr('for', value).children(input).not(id).eq(0).attr('id', value);
}
});
// :radio, :checkbox checked class
$(':radio, :checkbox').change(function(){
var $this = $(this);
if($this.is(':checked')){
$this.parent('label').addClass('checked');
}
$(':radio, :checkbox').not(':checked').parent('label').removeClass('checked');
}).change();
});
// Modal Window
jQuery(function($){