Minor improvements for feature handling with radio buttons

10.3.x-maintenance
KiteAnton 2016-07-26 23:58:23 +02:00
parent 12636365fc
commit b1516998f1
1 changed files with 4 additions and 4 deletions

View File

@ -152,17 +152,17 @@ Features.prototype.updateData = function (featureElement) {
var group = featureElement.attr('name');
var controlElements = $('input[name="' + group + '"]');
var selectedBit = controlElements.filter(':checked').val();
var thisFeature = this;
var featureMask = this._featureMask;
controlElements.each(function() {
var bit = $(this).val();
if (selectedBit === bit) {
thisFeature._featureMask = bit_set(thisFeature._featureMask, bit);
featureMask = bit_set(featureMask, bit);
} else {
thisFeature._featureMask = bit_clear(thisFeature._featureMask, bit);
featureMask = bit_clear(featureMask, bit);
}
});
this._featureMask = featureMask;
break;
}
}