From e38b82aa5daf633bc8bcdbeb25d3faf93abc6a96 Mon Sep 17 00:00:00 2001 From: Matthias Wirth Date: Thu, 22 Aug 2019 17:34:41 +0200 Subject: [PATCH] adjust label position a bit --- html/planeObject.js | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/html/planeObject.js b/html/planeObject.js index 7dee6e3..6d3542d 100644 --- a/html/planeObject.js +++ b/html/planeObject.js @@ -571,9 +571,8 @@ PlaneObject.prototype.updateIcon = function() { textAlign: 'left', textBaseline: "top", font: 'bold 12px tahoma', - offsetX: (5*this.scale), - offsetY: (14*this.scale), - zIndex: (this.zIndex-100000), + offsetX: (this.baseMarker.size[0]*0.5*0.74*this.scale), + offsetY: (this.baseMarker.size[0]*0.5*0.74*this.scale), }), zIndex: this.zIndex, }); @@ -978,10 +977,9 @@ PlaneObject.prototype.destroy = function() { this.tr.parentNode.removeChild(this.tr); this.tr = null; } - this.track_linesegs = null; - this.filter = null; - this.markerIcon = null; - this.markerStyle = null; if (this.icao == SelectedPlane) SelectedPlane = null; + for (var key in Object.keys(this)) { + delete this[key]; + } };