fix altitudeChart interaction with shift-H for hiding the buttons

This commit is contained in:
Matthias Wirth
2020-10-24 16:09:41 +02:00
parent 8a060e3fc2
commit a4c0deaa09

View File

@@ -110,6 +110,7 @@ let lastActive = new Date().getTime();
let inactive = 0;
let firstFetchDone = false;
let overrideMapType = null;
let altitudeChartDisplay;
let shareLink = '';
@@ -1533,6 +1534,8 @@ function initialize_map() {
$('#expand_sidebar_control').hide();
toggleSidebarVisibility();
toggleSidebarVisibility();
if (altitudeChartDisplay != 'show')
$('#altitude_chart').hide();
}
hideButtons = !hideButtons;
break;
@@ -3018,7 +3021,6 @@ function toggleMapDim(switchOn) {
}
function toggleAltitudeChart(switchToggle) {
let altitudeChartDisplay;
if (localStorage['altitudeChart']) {
altitudeChartDisplay = localStorage['altitudeChart'];
} else if (onMobile) {