From cd82d850acd97ec43345360d56edeb01ca052a49 Mon Sep 17 00:00:00 2001 From: Matthias Wirth Date: Wed, 23 Dec 2020 23:55:29 +0100 Subject: [PATCH] jaeroTimeout --- html/defaults.js | 2 ++ html/planeObject.js | 2 +- html/script.js | 4 ++++ 3 files changed, 7 insertions(+), 1 deletion(-) diff --git a/html/defaults.js b/html/defaults.js index d7ceb89..75c5066 100644 --- a/html/defaults.js +++ b/html/defaults.js @@ -277,6 +277,8 @@ let askLocation = false; // requires https for geolocation let filterMaxRange = 1e8; // 100 000 km should include all planes on earth ;) +let jaeroTimeout = 35 * 60; // in seconds + // legacy variables let OutlineMlatColor = null; diff --git a/html/planeObject.js b/html/planeObject.js index 69d8119..0c969d1 100644 --- a/html/planeObject.js +++ b/html/planeObject.js @@ -2500,7 +2500,7 @@ PlaneObject.prototype.isNonIcao = function() { PlaneObject.prototype.checkVisible = function() { const zoomedOut = refreshInt() / globeSimLoad * globeTilesViewCount / 1000; - const jaeroTime = (this.dataSource == "adsc") ? 35*60 : 0; + const jaeroTime = (this.dataSource == "adsc") ? jaeroTimeout : 0; const mlatTime = (this.dataSource == "mlat") ? 25 : 0; const tisbReduction = (this.icao[0] == '~') ? 15 : 0; // If no packet in over 58 seconds, clear the plane. diff --git a/html/script.js b/html/script.js index 65121f1..5ce05ff 100644 --- a/html/script.js +++ b/html/script.js @@ -1417,6 +1417,10 @@ function initMap() { DefaultCenterLon = receiverJson.lon; } + if (receiverJson && receiverJson.jaeroTimeout) { + jaeroTimeout = receiverJson.jaeroTimeout * 60; + } + if (receiverJson && receiverJson.globeIndexGrid != null) { globeIndexGrid = receiverJson.globeIndexGrid; globeIndex = 1;