debugging map failure
This commit is contained in:
@@ -370,10 +370,21 @@ public final class MapHtmlResources {
|
|||||||
|
|
||||||
jsLog('Leaflet map initialized');
|
jsLog('Leaflet map initialized');
|
||||||
|
|
||||||
L.tileLayer('https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', {
|
const osmTileLayer = L.tileLayer('https://tile.openstreetmap.org/{z}/{x}/{y}.png', {
|
||||||
maxZoom: 18,
|
maxZoom: 19,
|
||||||
attribution: '© OpenStreetMap'
|
attribution: '© OpenStreetMap contributors'
|
||||||
}).addTo(map);
|
});
|
||||||
|
|
||||||
|
osmTileLayer.on('tileload', function (event) {
|
||||||
|
jsLog('OSM tile loaded');
|
||||||
|
});
|
||||||
|
|
||||||
|
osmTileLayer.on('tileerror', function (event) {
|
||||||
|
const src = event && event.tile ? event.tile.src : 'unknown';
|
||||||
|
jsError('OSM tile load failed: ' + src);
|
||||||
|
});
|
||||||
|
|
||||||
|
osmTileLayer.addTo(map);
|
||||||
|
|
||||||
map.createPane('beamPane');
|
map.createPane('beamPane');
|
||||||
map.getPane('beamPane').style.zIndex = 410;
|
map.getPane('beamPane').style.zIndex = 410;
|
||||||
|
|||||||
@@ -627,6 +627,8 @@ public final class StationMapView {
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
webEngine.setUserAgent("KST4Contest (+https://hamradioonline.de)");
|
||||||
|
|
||||||
webEngine.loadContent(MapHtmlResources.createStationMapHtml());
|
webEngine.loadContent(MapHtmlResources.createStationMapHtml());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user