web/data/cubicweb.preferences.js
branchstable
changeset 2154 558079860667
parent 2133 c3beb65d884d
child 2155 1dd3dfc6fd76
equal deleted inserted replaced
2152:edec2c9055e5 2154:558079860667
   111      input.removeClass('error');
   111      input.removeClass('error');
   112      return unfreezeButtons;
   112      return unfreezeButtons;
   113 }
   113 }
   114 
   114 
   115 function setCurrentValues(form){
   115 function setCurrentValues(form){
   116     jQuery(form).find('input[name^=value]').each(function () {
   116     jQuery(form).find('[name^=value]').each(function () {
   117 	    var input = jQuery(this);
   117 	    var input = jQuery(this);
   118 	    if(input.attr('type') == 'radio'){
   118 	    if(input.attr('type') == 'radio'){
   119 		// NOTE: there seems to be a bug with jQuery(input).attr('checked')
   119 		// NOTE: there seems to be a bug with jQuery(input).attr('checked')
   120 		//       in our case, we can't rely on its value, we use
   120 		//       in our case, we can't rely on its value, we use
   121 		//       the DOM API instead.
   121 		//       the DOM API instead.
   125 	    }else{
   125 	    }else{
   126 		prefsValues[input.attr('name')] = input.val();
   126 		prefsValues[input.attr('name')] = input.val();
   127 	    }
   127 	    }
   128 	});
   128 	});
   129 }
   129 }
   130      
   130 
   131 function initEvents(){
   131 function initEvents(){
   132   jQuery('form').each(function() {
   132   jQuery('form').each(function() {
   133 	  var form = jQuery(this);
   133 	  var form = jQuery(this);
   134 	  freezeFormButtons(form.attr('id'));
   134 	  freezeFormButtons(form.attr('id'));
   135 	  form.find('input[type=text]').keyup(function(){
   135 	  form.find('input[type=text]').keyup(function(){