1
0
Fork 0
mirror of https://github.com/betaflight/betaflight-configurator.git synced 2025-07-16 12:55:14 +03:00

Bugfix for feature selection with radio buttons

This commit is contained in:
KiteAnton 2016-07-26 15:10:23 +02:00
parent f9ee83d52e
commit 12636365fc

View file

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