From 7a6d0a0d313037f4c082a0c715505025a99fb995 Mon Sep 17 00:00:00 2001 From: "Sascha L. Teichmann" Date: Fri, 13 Mar 2015 17:06:50 +0100 Subject: [PATCH] Fixed none vanishing manual update control when switching to auto update. --- cmd/mtwebmapper/web/index.html | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/cmd/mtwebmapper/web/index.html b/cmd/mtwebmapper/web/index.html index daafae3..85345af 100644 --- a/cmd/mtwebmapper/web/index.html +++ b/cmd/mtwebmapper/web/index.html @@ -118,12 +118,8 @@ L.control.coordinates({ var manualUpdateControl; if (useWebsocket && 'WebSocket' in window) { L.autoUpdate('autoUpdate', function(pressed) { - if (pressed) { - manualUpdateControl.getContainer().style = 'visibility: hidden'; - } - else { - manualUpdateControl.getContainer().style = 'visibility: visible'; - } + var styleDec = manualUpdateControl.getContainer().style; + styleDec.visibility = pressed ? 'hidden' : 'visible'; }, players); }