Skip to content

Commit ebdc2a0

Browse files
xssfoxTheSkorm
authored andcommitted
fix performance issue with tooltips and fix rangering titles not being in right spot
1 parent 2be0432 commit ebdc2a0

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

js/sondehub.js

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3347,9 +3347,9 @@ function addPosition(position) {
33473347

33483348
if (!offline.get("opt_hide_titles")) {
33493349
if (vehicle_type == "car") {
3350-
title = marker.bindTooltip(vcallsign, {direction: 'center', permanent: 'true', className: 'serialtooltip'});
3350+
title = marker.bindTooltip(vcallsign, {direction: 'center', permanent: 'false', className: 'serialtooltip'});
33513351
} else {
3352-
title = marker.bindTooltip((tempTitle), {direction: 'center', permanent: 'true', className: 'serialtooltip'});
3352+
title = marker.bindTooltip((tempTitle), {direction: 'center', permanent: 'false', className: 'serialtooltip'});
33533353
}
33543354
} else {
33553355
title = null;
@@ -4933,6 +4933,8 @@ function showHorizonRings(){
49334933
if(vehicles[vcallsign].vehicle_type == "balloon"){
49344934
map.addLayer(vehicles[vcallsign].horizon_circle);
49354935
map.addLayer(vehicles[vcallsign].subhorizon_circle);
4936+
vehicles[vcallsign].horizon_circle.fire("move")
4937+
vehicles[vcallsign].subhorizon_circle.fire("move")
49364938
map.addLayer(vehicles[vcallsign].horizon_circle_title);
49374939
map.addLayer(vehicles[vcallsign].subhorizon_circle_title);
49384940
}
@@ -4950,7 +4952,7 @@ function hideTitles(){
49504952
function showTitles(){
49514953
for(var vcallsign in vehicles) {
49524954
if(vehicles[vcallsign].vehicle_type == "balloon" || vehicles[vcallsign].vehicle_type == "car"){
4953-
vehicles[vcallsign].title = vehicles[vcallsign].marker.bindTooltip(vehicles[vcallsign]["marker"]["options"]["title"], {direction: 'center', permanent: 'true', className: 'serialtooltip'});
4955+
vehicles[vcallsign].title = vehicles[vcallsign].marker.bindTooltip(vehicles[vcallsign]["marker"]["options"]["title"], {direction: 'center', permanent: 'false', className: 'serialtooltip'});
49544956
}
49554957
}
49564958
}

0 commit comments

Comments
 (0)