mirror of
https://github.com/betaflight/betaflight-configurator.git
synced 2025-07-19 14:25:14 +03:00
Fix Expert Mode Switch
This commit is contained in:
parent
2d268ee115
commit
5c151e0d4f
2 changed files with 4 additions and 4 deletions
|
@ -501,12 +501,12 @@ function startProcess() {
|
||||||
});
|
});
|
||||||
|
|
||||||
ConfigStorage.get('permanentExpertMode', function (result) {
|
ConfigStorage.get('permanentExpertMode', function (result) {
|
||||||
const experModeCheckbox = 'input[name="expertModeCheckbox"]';
|
const expertModeCheckbox = 'input[name="expertModeCheckbox"]';
|
||||||
if (result.permanentExpertMode) {
|
if (result.permanentExpertMode) {
|
||||||
$(experModeCheckbox).prop('checked', true);
|
$(expertModeCheckbox).prop('checked', true);
|
||||||
}
|
}
|
||||||
|
|
||||||
$(experModeCheckbox).change(function () {
|
$(expertModeCheckbox).change(function () {
|
||||||
const checked = $(this).is(':checked');
|
const checked = $(this).is(':checked');
|
||||||
checkSetupAnalytics(function (analyticsService) {
|
checkSetupAnalytics(function (analyticsService) {
|
||||||
analyticsService.setDimension(analyticsService.DIMENSIONS.CONFIGURATOR_EXPERT_MODE, checked ? 'On' : 'Off');
|
analyticsService.setDimension(analyticsService.DIMENSIONS.CONFIGURATOR_EXPERT_MODE, checked ? 'On' : 'Off');
|
||||||
|
|
|
@ -376,7 +376,7 @@ firmware_flasher.initialize = function (callback) {
|
||||||
function showOrHideBuildTypeSelect() {
|
function showOrHideBuildTypeSelect() {
|
||||||
const expertModeChecked = $(this).is(':checked');
|
const expertModeChecked = $(this).is(':checked');
|
||||||
|
|
||||||
globalExpertMode_e.prop('checked', expertModeChecked);
|
globalExpertMode_e.prop('checked', expertModeChecked).trigger('change');
|
||||||
if (expertModeChecked) {
|
if (expertModeChecked) {
|
||||||
buildTypesToShow = buildTypes.concat(ciBuildsTypes);
|
buildTypesToShow = buildTypes.concat(ciBuildsTypes);
|
||||||
buildBuildTypeOptionsList();
|
buildBuildTypeOptionsList();
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue