Skip to content

Commit

Permalink
Merge pull request #2211 from error414/speed-up-osd-preview
Browse files Browse the repository at this point in the history
  • Loading branch information
MrD-RC authored Oct 16, 2024
2 parents 1a3090d + 4546a73 commit 4150613
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions tabs/osd.js
Original file line number Diff line number Diff line change
Expand Up @@ -3549,6 +3549,7 @@ function createCustomElements(){
}

var customElementsContainer = $('#osdCustomElements');
var init = true;

for(var i = 0; i < FC.OSD_CUSTOM_ELEMENTS.settings.customElementsCount; i++){
var label = $('<label>');
Expand Down Expand Up @@ -3606,7 +3607,9 @@ function createCustomElements(){
var valueBlock = $('.' + $(this).data('valueCellClass'))
valueBlock.find('.value').hide();
valueBlock.find('.' + dataValue).show();
updateOSDCustomElementsDisplay();
if(!init){
updateOSDCustomElementsDisplay();
}
});
}

Expand Down Expand Up @@ -3636,6 +3639,7 @@ function createCustomElements(){

fillCustomElementsValues();
customElementsInitCallback();
init = false;
}

function updateOSDCustomElementsDisplay() {
Expand Down Expand Up @@ -4079,4 +4083,4 @@ TABS.osd.cleanup = function (callback) {
$('.jBox-wrapper').remove();

if (callback) callback();
};
};

0 comments on commit 4150613

Please sign in to comment.