mirror of
https://github.com/betaflight/betaflight-configurator.git
synced 2025-07-21 15:25:22 +03:00
Update configuration.js
This commit is contained in:
parent
02bd2660e0
commit
69c18377cf
1 changed files with 32 additions and 5 deletions
|
@ -90,14 +90,41 @@ TABS.configuration.initialize = function (callback, scrollPosition) {
|
||||||
for (var i = 0; i < features.length; i++) {
|
for (var i = 0; i < features.length; i++) {
|
||||||
var row_e;
|
var row_e;
|
||||||
|
|
||||||
if (features[i].mode == 'group') {
|
if (features[i].mode === 'group') {
|
||||||
row_e = $('<tr><td><input class="feature" id="feature-' + i + '" value="' + features[i].bit + '" title="' + features[i].name + '" type="radio" name="' + features[i].group + '" /></td><td><label for="feature-' + i + '">' + features[i].name + '</label></td><td>' + features[i].description + '</td>');
|
row_e = $('<tr><td><input class="feature" id="feature-'
|
||||||
|
+ i
|
||||||
|
+ '" value="'
|
||||||
|
+ features[i].bit
|
||||||
|
+ '" title="'
|
||||||
|
+ features[i].name
|
||||||
|
+ '" type="radio" name="'
|
||||||
|
+ features[i].group
|
||||||
|
+ '" /></td><td><label for="feature-'
|
||||||
|
+ i
|
||||||
|
+ '">'
|
||||||
|
+ features[i].name
|
||||||
|
+ '</label></td><td>'
|
||||||
|
+ features[i].description
|
||||||
|
+ '</td>');
|
||||||
radioGroups.push(features[i].group);
|
radioGroups.push(features[i].group);
|
||||||
} else {
|
} else {
|
||||||
row_e = $('<tr><td><input class="feature" id="feature-' + i + '" title="' + features[i].name + '" type="checkbox" /></td><td><label for="feature-' + i + '">' + features[i].name + '</label></td><td>' + features[i].description + '</td>');
|
var feature_e = row_e.find('input.feature');
|
||||||
var feature_e = row_e.find('input.feature');
|
row_e = $('<tr><td><input class="feature" id="feature-'
|
||||||
feature_e.data('bit', features[i].bit);
|
+ i
|
||||||
|
+ '" name="'
|
||||||
|
+ features[i].name
|
||||||
|
+ '" title="'
|
||||||
|
+ features[i].name
|
||||||
|
+ '" type="checkbox" /></td><td><label for="feature-'
|
||||||
|
+ i
|
||||||
|
+ '">'
|
||||||
|
+ features[i].name
|
||||||
|
+ '</label></td><td>'
|
||||||
|
+ features[i].description
|
||||||
|
+ '</td>');
|
||||||
|
|
||||||
feature_e.prop('checked', bit_check(BF_CONFIG.features, features[i].bit));
|
feature_e.prop('checked', bit_check(BF_CONFIG.features, features[i].bit));
|
||||||
|
feature_e.data('bit', features[i].bit);
|
||||||
}
|
}
|
||||||
|
|
||||||
features_e.each(function () {
|
features_e.each(function () {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue