Display craftname in OSD preview

10.3.x-maintenance
Bas Delfos 2017-07-15 14:48:16 +02:00
parent 667c4d5af3
commit 5b16361f3b
1 changed files with 11 additions and 1 deletions

View File

@ -254,6 +254,13 @@ OSD.generateTimerPreview = function(osd_data, timer_index) {
return preview;
};
OSD.generateCraftName = function(osd_data) {
var preview = 'CRAFT_NAME';
if (CONFIG.name != '')
preview = CONFIG.name.toUpperCase();
return preview;
}
OSD.constants = {
VISIBLE: 0x0800,
VIDEO_TYPES: [
@ -383,7 +390,10 @@ OSD.constants = {
desc: 'osdDescElementCraftName',
default_position: -77,
positionable: true,
preview: 'CRAFT_NAME'
preview: function(osd_data) {
return OSD.generateCraftName(osd_data, 1);
}
//preview: 'c'
},
ALTITUDE: {
name: 'ALTITUDE',