diff --git a/public_html/layers/UK_Civi_Airports_named.geojson b/public_html/layers/UK_Civi_Airports_named.geojson index 0c25a983..0a8e7891 100644 --- a/public_html/layers/UK_Civi_Airports_named.geojson +++ b/public_html/layers/UK_Civi_Airports_named.geojson @@ -24,7 +24,7 @@ { "type": "Feature", "properties": { "id": null, "notes_1": "Prestwick" }, "geometry": { "type": "LineString", "coordinates": [ [ -4.579723750859277, 55.510778720157148 ], [ -4.598424611341413, 55.505616056699324 ] ] } }, { "type": "Feature", "properties": { "id": null, "notes_1": "Prestwick" }, "geometry": { "type": "LineString", "coordinates": [ [ -4.587515776060166, 55.488578877895627 ], [ -4.575749818006822, 55.503453714435913 ] ] } }, { "type": "Feature", "properties": { "id": 12, "name_1": "Newcastle", "ident_1": "NCL", "notes_1": "Newcastle" }, "geometry": { "type": "LineString", "coordinates": [ [ -1.706648218787066, 55.033509466861865 ], [ -1.673064590171229, 55.042350356119037 ] ] } }, -{ "type": "Feature", "id": 21, "properties": { "id": 13, "name_1": "Teeside", "ident_1": "MME", "notes_1": "Teeside" }, "geometry": { "type": "LineString", "coordinates": [ [ -1.44327776699698, 54.501694906330357 ], [ -1.414758954761722, 54.517166329032648 ] ] } }, +{ "type": "Feature", "properties": { "id": 13, "name_1": "Teeside", "ident_1": "MME", "notes_1": "Teeside" }, "geometry": { "type": "LineString", "coordinates": [ [ -1.44327776699698, 54.501694906330357 ], [ -1.414758954761722, 54.517166329032648 ] ] } }, { "type": "Feature", "properties": { "id": null, "notes_1": "Teeside" }, "geometry": { "type": "LineString", "coordinates": [ [ -1.419590010386274, 54.517754308464077 ], [ -1.420447133158372, 54.50667173410055 ] ] } }, { "type": "Feature", "properties": { "id": null, "notes_1": "Teeside" }, "geometry": { "type": "LineString", "coordinates": [ [ -1.413901831989624, 54.510109915586263 ], [ -1.432057250707698, 54.510697996598878 ] ] } }, { "type": "Feature", "properties": { "id": 14, "name_1": "Liverpool", "ident_1": "LPL", "notes_1": "Liverpool" }, "geometry": { "type": "LineString", "coordinates": [ [ -2.866491169939565, 53.332940151192503 ], [ -2.832907541323728, 53.334429122863696 ] ] } }, @@ -56,7 +56,7 @@ { "type": "Feature", "properties": { "id": 28, "name_1": "Cardiff", "ident_1": "CWL", "notes_1": "Cardiff" }, "geometry": { "type": "LineString", "coordinates": [ [ -3.357914719296703, 51.401191218996864 ], [ -3.328227103281311, 51.391808219959515 ] ] } }, { "type": "Feature", "properties": { "id": null, "notes_1": "Cardiff" }, "geometry": { "type": "LineString", "coordinates": [ [ -3.343811153683092, 51.402989812435372 ], [ -3.352304461152062, 51.392148569623771 ] ] } }, { "type": "Feature", "properties": { "id": 29, "name_1": "Saint Athan", "ident_1": "EGSY", "notes_1": "Saint Athan" }, "geometry": { "type": "LineString", "coordinates": [ [ -3.445613962932722, 51.402843983169959 ], [ -3.420991163297909, 51.407534591456681 ] ] } }, -{ "type": "Feature", "properties": { "id": 30, "name_1": "Himberside", "ident_1": "HUY", "notes_1": "Himberside" }, "geometry": { "type": "LineString", "coordinates": [ [ -0.344260380048858, 53.583690716033438 ], [ -0.357000268929807, 53.565381776356425 ] ] } }, +{ "type": "Feature", "properties": { "id": 30, "name_1": "Humberside", "ident_1": "HUY", "notes_1": "Humberside" }, "geometry": { "type": "LineString", "coordinates": [ [ -0.344260380048858, 53.583690716033438 ], [ -0.357000268929807, 53.565381776356425 ] ] } }, { "type": "Feature", "properties": { "id": null, "notes_1": "Humberside" }, "geometry": { "type": "LineString", "coordinates": [ [ -0.353045303425556, 53.575836092105398 ], [ -0.33845043072403, 53.576958270591938 ] ] } }, { "type": "Feature", "properties": { "id": 31, "name_1": "Dublin", "ident_1": "DUB", "notes_1": "Dublin" }, "geometry": { "type": "LineString", "coordinates": [ [ -6.290271018131773, 53.422431198955373 ], [ -6.251106359731274, 53.420303763703558 ] ] } }, { "type": "Feature", "properties": { "id": null, "notes_1": "Dublin" }, "geometry": { "type": "LineString", "coordinates": [ [ -6.249601372857975, 53.419970038711448 ], [ -6.26192126540219, 53.436903275671682 ] ] } }, diff --git a/public_html/script.js b/public_html/script.js index 40a62729..77ac0e4c 100644 --- a/public_html/script.js +++ b/public_html/script.js @@ -786,7 +786,7 @@ function initialize_map() { }); var styles = [style]; return function (feature, resolution) { - if (ShowAirfieldNames) { + if (ShowAirfieldNames && ZoomLvl > 7.5) { style.getText().setText(feature.get("name_1")); }else style.getText().setText(""); return styles; @@ -836,6 +836,8 @@ function initialize_map() { if (ShowUKMilLayers) { + // LAYERS for UK Military + var matzafLayer= new ol.layer.Vector({ name: "matzaf", type: "overlay", @@ -866,7 +868,7 @@ function initialize_map() { }); var styles = [style]; return function (feature, resolution) { - if (ShowAirfieldNames) { + if (ShowAirfieldNames && ZoomLvl > 7.5) { style.getText().setText(feature.get("name_1")); }else style.getText().setText(""); return styles; @@ -875,8 +877,6 @@ function initialize_map() { }); - - // LAYERS for UK Military var awacLayer = new ol.layer.Vector({ name: "awac", type: "overlay", @@ -1284,7 +1284,7 @@ function initialize_map() { var akrng = ol.sphere.getDistance(SitePosition, coord1); return ( akret + " " + akbrn + "\u00B0 " + - format_distance_long(akrng, DisplayUnits, 0) + format_distance_long(akrng, DisplayUnits, 0) //+ " "+ZoomLvl ); } else { return akret; // no range or bearing required, just return akret @@ -1293,7 +1293,7 @@ function initialize_map() { }; var mousePosition = new ol.control.MousePosition({ - coordinateFormat: llFormat(3), // ol.coordinate.createStringXY(4), + coordinateFormat: llFormat(3), projection: "EPSG:4326", target: document.getElementById("mouseposition"), undefinedHTML: " ",