diff --git a/src/trx-client/trx-frontend/trx-frontend-http/assets/web/app.js b/src/trx-client/trx-frontend/trx-frontend-http/assets/web/app.js index 4bd3d2f..280408e 100644 --- a/src/trx-client/trx-frontend/trx-frontend-http/assets/web/app.js +++ b/src/trx-client/trx-frontend/trx-frontend-http/assets/web/app.js @@ -6522,7 +6522,7 @@ window.syncBookmarkMapLocators = function(bookmarks) { applyMapFilter(); }; -window.ft8MapAddLocator = function(message, grids, type = "ft8", station = null, details = null) { +window.mapAddLocator = function(message, grids, type = "ft8", station = null, details = null) { if (!Array.isArray(grids) || grids.length === 0) return; const markerType = type === "wspr" ? "wspr" : (type === "ft4" ? "ft4" : "ft8"); const unique = [...new Set(grids.map((g) => String(g).toUpperCase()))]; diff --git a/src/trx-client/trx-frontend/trx-frontend-http/assets/web/plugins/ft4.js b/src/trx-client/trx-frontend/trx-frontend-http/assets/web/plugins/ft4.js index 9cd97dd..372a49c 100644 --- a/src/trx-client/trx-frontend/trx-frontend-http/assets/web/plugins/ft4.js +++ b/src/trx-client/trx-frontend/trx-frontend-http/assets/web/plugins/ft4.js @@ -131,8 +131,8 @@ window.onServerFt4Batch = function(messages) { const normalized = []; for (const msg of messages) { const next = normalizeServerFt4Message(msg); - if (next.grids.length > 0 && window.ft8MapAddLocator) { - window.ft8MapAddLocator(next.raw, next.grids, "ft4", next.station, { ...msg, freq_hz: next.rfHz, locator_details: next.locatorDetails }); + if (next.grids.length > 0 && window.mapAddLocator) { + window.mapAddLocator(next.raw, next.grids, "ft4", next.station, { ...msg, freq_hz: next.rfHz, locator_details: next.locatorDetails }); } next.history._tsMs = Number.isFinite(next.history?.ts_ms) ? Number(next.history.ts_ms) : Date.now(); normalized.push(next.history); @@ -182,8 +182,8 @@ document.getElementById("ft4-clear-btn")?.addEventListener("click", async () => window.onServerFt4 = function(msg) { if (ft4Status) ft4Status.textContent = ft4Paused ? "Paused" : "Receiving"; const next = normalizeServerFt4Message(msg); - if (next.grids.length > 0 && window.ft8MapAddLocator) { - window.ft8MapAddLocator(next.raw, next.grids, "ft4", next.station, { ...msg, freq_hz: next.rfHz, locator_details: next.locatorDetails }); + if (next.grids.length > 0 && window.mapAddLocator) { + window.mapAddLocator(next.raw, next.grids, "ft4", next.station, { ...msg, freq_hz: next.rfHz, locator_details: next.locatorDetails }); } addFt4Message(next.history); }; diff --git a/src/trx-client/trx-frontend/trx-frontend-http/assets/web/plugins/ft8.js b/src/trx-client/trx-frontend/trx-frontend-http/assets/web/plugins/ft8.js index 3594381..6d1292c 100644 --- a/src/trx-client/trx-frontend/trx-frontend-http/assets/web/plugins/ft8.js +++ b/src/trx-client/trx-frontend/trx-frontend-http/assets/web/plugins/ft8.js @@ -145,8 +145,8 @@ window.onServerFt8Batch = function(messages) { const normalized = []; for (const msg of messages) { const next = normalizeServerFt8Message(msg); - if (next.grids.length > 0 && window.ft8MapAddLocator) { - window.ft8MapAddLocator(next.raw, next.grids, "ft8", next.station, { + if (next.grids.length > 0 && window.mapAddLocator) { + window.mapAddLocator(next.raw, next.grids, "ft8", next.station, { ...msg, freq_hz: next.rfHz, locator_details: next.locatorDetails, @@ -443,8 +443,8 @@ document.getElementById("ft8-clear-btn").addEventListener("click", async () => { window.onServerFt8 = function(msg) { ft8Status.textContent = ft8Paused ? "Paused" : "Receiving"; const next = normalizeServerFt8Message(msg); - if (next.grids.length > 0 && window.ft8MapAddLocator) { - window.ft8MapAddLocator(next.raw, next.grids, "ft8", next.station, { + if (next.grids.length > 0 && window.mapAddLocator) { + window.mapAddLocator(next.raw, next.grids, "ft8", next.station, { ...msg, freq_hz: next.rfHz, locator_details: next.locatorDetails, diff --git a/src/trx-client/trx-frontend/trx-frontend-http/assets/web/plugins/wspr.js b/src/trx-client/trx-frontend/trx-frontend-http/assets/web/plugins/wspr.js index 2449c0a..427ffc4 100644 --- a/src/trx-client/trx-frontend/trx-frontend-http/assets/web/plugins/wspr.js +++ b/src/trx-client/trx-frontend/trx-frontend-http/assets/web/plugins/wspr.js @@ -124,8 +124,8 @@ window.onServerWsprBatch = function(messages) { const normalized = []; for (const msg of messages) { const next = normalizeServerWsprMessage(msg); - if (next.grids.length > 0 && window.ft8MapAddLocator) { - window.ft8MapAddLocator(next.raw, next.grids, "wspr", next.station, { + if (next.grids.length > 0 && window.mapAddLocator) { + window.mapAddLocator(next.raw, next.grids, "wspr", next.station, { ...msg, freq_hz: next.rfHz, }); @@ -307,8 +307,8 @@ document.getElementById("wspr-clear-btn").addEventListener("click", async () => window.onServerWspr = function(msg) { wsprStatus.textContent = wsprPaused ? "Paused" : "Receiving"; const next = normalizeServerWsprMessage(msg); - if (next.grids.length > 0 && window.ft8MapAddLocator) { - window.ft8MapAddLocator(next.raw, next.grids, "wspr", next.station, { + if (next.grids.length > 0 && window.mapAddLocator) { + window.mapAddLocator(next.raw, next.grids, "wspr", next.station, { ...msg, freq_hz: next.rfHz, });