1
0
Fork 0
mirror of https://github.com/betaflight/betaflight-configurator.git synced 2025-07-24 00:35:26 +03:00

Merge pull request #1968 from atomgomba/fix/osd-save-button-restore-label-after-save

Fix OSD tab save button behavior
This commit is contained in:
Michael Keller 2020-04-20 01:59:02 +12:00 committed by GitHub
commit 1dc0aa3c82
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -2799,11 +2799,11 @@ TABS.osd.initialize = function (callback) {
$('a.save').click(function () {
MSP.promise(MSPCodes.MSP_EEPROM_WRITE);
GUI.log(i18n.getMessage('osdSettingsSaved'));
var oldText = $(this).text();
const oldText = $(this).html();
$(this).html(i18n.getMessage('osdButtonSaved'));
setTimeout(function () {
setTimeout(() => {
$(this).html(oldText);
}, 2000);
}, 1500);
Object.keys(self.analyticsChanges).forEach(function (change) {
const value = self.analyticsChanges[change];