diff --git a/Panels/LayersPanel.js b/Panels/LayersPanel.js index b5bed93e9..1d50fc947 100644 --- a/Panels/LayersPanel.js +++ b/Panels/LayersPanel.js @@ -227,7 +227,7 @@ function newLayersPanel () { } function panelSizePhysics () { - if (isInitialized === false || thisObject.visible === false || thisObject.isHidden === true) { return } + if (isInitialized === false || thisObject.isHidden === true) { return } let viewPortHeight = canvas.chartingSpace.viewport.visibleArea.bottomLeft.y - canvas.chartingSpace.viewport.visibleArea.topLeft.y @@ -237,6 +237,8 @@ function newLayersPanel () { thisObject.visible = true } + if (thisObject.visible === false) { return } + if (desiredPanelHeight > viewPortHeight) { posibleVisibleLayers = Math.trunc((viewPortHeight - headerHeight - footerHeight) / (layerHeight + LAYER_SEPARATION)) } else {