You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@myfaces.apache.org by lo...@apache.org on 2012/12/05 14:08:30 UTC
svn commit: r1417405 -
/myfaces/tobago/trunk/tobago-theme/tobago-theme-standard/src/main/resources/org/apache/myfaces/tobago/renderkit/html/standard/standard/script/tobago.js
Author: lofwyr
Date: Wed Dec 5 13:08:29 2012
New Revision: 1417405
URL: http://svn.apache.org/viewvc?rev=1417405&view=rev
Log:
readonly radio button aren't work
- syntax error
Modified:
myfaces/tobago/trunk/tobago-theme/tobago-theme-standard/src/main/resources/org/apache/myfaces/tobago/renderkit/html/standard/standard/script/tobago.js
Modified: myfaces/tobago/trunk/tobago-theme/tobago-theme-standard/src/main/resources/org/apache/myfaces/tobago/renderkit/html/standard/standard/script/tobago.js
URL: http://svn.apache.org/viewvc/myfaces/tobago/trunk/tobago-theme/tobago-theme-standard/src/main/resources/org/apache/myfaces/tobago/renderkit/html/standard/standard/script/tobago.js?rev=1417405&r1=1417404&r2=1417405&view=diff
==============================================================================
--- myfaces/tobago/trunk/tobago-theme/tobago-theme-standard/src/main/resources/org/apache/myfaces/tobago/renderkit/html/standard/standard/script/tobago.js (original)
+++ myfaces/tobago/trunk/tobago-theme/tobago-theme-standard/src/main/resources/org/apache/myfaces/tobago/renderkit/html/standard/standard/script/tobago.js Wed Dec 5 13:08:29 2012
@@ -2746,30 +2746,30 @@ Tobago.SelectOneRadio.init = function(el
var radios = jQuery('input[name="' + ul.attr('id').replace(/:/g, '\\:') + '"]');
radios.each(function () {
var selectOneRadio = jQuery(this);
- selectOneRadio.data('oldValue', selectOneRadio.attr('checked'));
+ selectOneRadio.data("oldValue", selectOneRadio.prop("checked"));
});
radios.click(function() {
var selectOneRadio = jQuery(this);
- var readonly = selectOneRadio.attr('readonly');
- var required = selectOneRadio.attr('required');
+ var readonly = selectOneRadio.prop("readonly");
+ var required = selectOneRadio.prop("required");
if (!required && !readonly) {
- if (selectOneRadio.data('oldValue') == selectOneRadio.attr('checked')) {
- selectOneRadio.attr('checked', false);
+ if (selectOneRadio.data("oldValue") == selectOneRadio.prop("checked")) {
+ selectOneRadio.prop("checked", false);
}
- selectOneRadio.data('oldValue', selectOneRadio.attr('checked'));
+ selectOneRadio.data("oldValue", selectOneRadio.prop("checked"));
}
var radios = jQuery('input[name="' + ul.attr('id').replace(/:/g, '\\:') + '"]');
if (readonly) {
radios.each(function () {
var radio = jQuery(this);
- radio.attr('checked'. radio.data('oldValue'));
+ radio.prop("checked", radio.data("oldValue"));
});
} else {
radios.each(function () {
if (this.id != selectOneRadio.get(0).id) {
var radio = jQuery(this);
- radio.attr('checked', false);
- radio.data('oldValue', radio.attr('checked'));
+ radio.prop("checked", false);
+ radio.data("oldValue", radio.prop("checked"));
}
});
}