From ec996bd41ba40aa7509e74b80ec331e189e5cbe1 Mon Sep 17 00:00:00 2001 From: Luis Fernando Molina Date: Sun, 8 Mar 2020 18:17:58 +0100 Subject: [PATCH] Improvements on layer panels --- ChartingSpace/TimeMachine.js | 5 ++++- Frame.js | 8 ++++---- 2 files changed, 8 insertions(+), 5 deletions(-) diff --git a/ChartingSpace/TimeMachine.js b/ChartingSpace/TimeMachine.js index acff57ffd..cfa079129 100644 --- a/ChartingSpace/TimeMachine.js +++ b/ChartingSpace/TimeMachine.js @@ -417,7 +417,10 @@ function newTimeMachine () { } function panelPhysics () { - if (thisObject.container.frame.isCenterInViewPort() && canvas.chartingSpace.viewport.zoomTargetLevel >= ZOOM_OUT_THRESHOLD_FOR_HIDDING_PANELS) { + if ( + thisObject.container.frame.isCenterInViewPort() && + canvas.chartingSpace.viewport.zoomLevel >= ZOOM_OUT_THRESHOLD_FOR_HIDDING_PANELS + ) { canvas.panelsSpace.unHide(thisObject.payload.node.id, 'Layers Panel') canvas.panelsSpace.unHide(thisObject.payload.node.id, 'Plotter Panel') } else { diff --git a/Frame.js b/Frame.js index 01ad949db..04cec82ad 100644 --- a/Frame.js +++ b/Frame.js @@ -81,13 +81,13 @@ function newFrame () { /* This function is usefull to know if the object who has this frame is currently appearing at least in part at the canvas.chartingSpace.viewport */ point1 = { - x: thisObject.width * 25 / 100, - y: thisObject.height * 25 / 100 + x: thisObject.width * 40 / 100, + y: thisObject.height * 40 / 100 } point3 = { - x: thisObject.width * 75 / 100, - y: thisObject.height * 75 / 100 + x: thisObject.width * 40 / 100, + y: thisObject.height * 40 / 100 } /* Now the transformations. */