Merge remote-tracking branch 'csfa/map_enhancements' into dev
This commit is contained in:
commit
f8a2896e76
|
@ -199,7 +199,7 @@
|
||||||
</thead>
|
</thead>
|
||||||
<tbody>
|
<tbody>
|
||||||
<tr id="plane_row_template" class="plane_table_row hidden">
|
<tr id="plane_row_template" class="plane_table_row hidden">
|
||||||
<td style="text-transform: uppercase">ICAO</td>
|
<td class="icaoCodeColumn">ICAO</td>
|
||||||
<td><img style="width: 20px; height=12px" src="about:blank" alt="Flag"></td>
|
<td><img style="width: 20px; height=12px" src="about:blank" alt="Flag"></td>
|
||||||
<td>FLIGHT</td>
|
<td>FLIGHT</td>
|
||||||
<td>REGISTRATION</td>
|
<td>REGISTRATION</td>
|
||||||
|
|
|
@ -217,14 +217,10 @@ PlaneObject.prototype.getDataSource = function() {
|
||||||
return 'adsb';
|
return 'adsb';
|
||||||
}
|
}
|
||||||
|
|
||||||
var emptyHexRegex = /^0*$/;
|
// Otherwise Mode S
|
||||||
// No position and no ICAO hex code - Mode A/C
|
|
||||||
if (emptyHexRegex.test(this.icao)) {
|
|
||||||
return 'mode_ac';
|
|
||||||
}
|
|
||||||
|
|
||||||
// No position and ICAO hex code present - Mode S
|
|
||||||
return 'mode_s';
|
return 'mode_s';
|
||||||
|
|
||||||
|
// TODO: add support for Mode A/C
|
||||||
};
|
};
|
||||||
|
|
||||||
PlaneObject.prototype.getMarkerColor = function() {
|
PlaneObject.prototype.getMarkerColor = function() {
|
||||||
|
|
|
@ -8,7 +8,7 @@ var SiteCircleFeatures = new ol.Collection();
|
||||||
var PlaneIconFeatures = new ol.Collection();
|
var PlaneIconFeatures = new ol.Collection();
|
||||||
var PlaneTrailFeatures = new ol.Collection();
|
var PlaneTrailFeatures = new ol.Collection();
|
||||||
var Planes = {};
|
var Planes = {};
|
||||||
var PlanesModeAc = {};
|
var PlanesNoHex = {};
|
||||||
var PlanesOrdered = [];
|
var PlanesOrdered = [];
|
||||||
var PlaneFilter = {};
|
var PlaneFilter = {};
|
||||||
var SelectedPlane = null;
|
var SelectedPlane = null;
|
||||||
|
@ -74,8 +74,8 @@ function processReceiverUpdate(data) {
|
||||||
|
|
||||||
if (hex !== "000000" && Planes[hex]) {
|
if (hex !== "000000" && Planes[hex]) {
|
||||||
plane = Planes[hex];
|
plane = Planes[hex];
|
||||||
} else if (hex === "000000" && PlanesModeAc[squawk]) {
|
} else if (hex === "000000" && PlanesNoHex[squawk]) {
|
||||||
plane = PlanesModeAc[squawk];
|
plane = PlanesNoHex[squawk];
|
||||||
} else {
|
} else {
|
||||||
plane = new PlaneObject(hex);
|
plane = new PlaneObject(hex);
|
||||||
plane.filter = PlaneFilter;
|
plane.filter = PlaneFilter;
|
||||||
|
@ -123,7 +123,7 @@ function processReceiverUpdate(data) {
|
||||||
|
|
||||||
Planes[hex] = plane;
|
Planes[hex] = plane;
|
||||||
} else {
|
} else {
|
||||||
PlanesModeAc[squawk] = plane;
|
PlanesNoHex[squawk] = plane;
|
||||||
}
|
}
|
||||||
PlanesOrdered.push(plane);
|
PlanesOrdered.push(plane);
|
||||||
}
|
}
|
||||||
|
@ -695,7 +695,7 @@ function reaper() {
|
||||||
plane.tr.parentNode.removeChild(plane.tr);
|
plane.tr.parentNode.removeChild(plane.tr);
|
||||||
plane.tr = null;
|
plane.tr = null;
|
||||||
if (plane.icao === "000000") {
|
if (plane.icao === "000000") {
|
||||||
delete PlanesModeAc[plane.squawk];
|
delete PlanesNoHex[plane.squawk];
|
||||||
} else {
|
} else {
|
||||||
delete Planes[plane.icao];
|
delete Planes[plane.icao];
|
||||||
}
|
}
|
||||||
|
|
|
@ -134,6 +134,11 @@ div#loader { z-index: 99; position: absolute; left: 0; top: 0; bottom: 0; right:
|
||||||
font-family: "Courier New",monospace;
|
font-family: "Courier New",monospace;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.icaoCodeColumn {
|
||||||
|
font-family: monospace;
|
||||||
|
text-transform: uppercase;
|
||||||
|
}
|
||||||
|
|
||||||
.vPosition { background-color: #C3FFDF; }
|
.vPosition { background-color: #C3FFDF; }
|
||||||
.mlat { background-color: #C7EAFC; }
|
.mlat { background-color: #C7EAFC; }
|
||||||
.squawk7500 { font-weight: bold; background-color: #ff5555; }
|
.squawk7500 { font-weight: bold; background-color: #ff5555; }
|
||||||
|
|
Loading…
Reference in a new issue