From 958a92280845ba9833ca3dae5b86cecd8b0aaf24 Mon Sep 17 00:00:00 2001 From: Nino van Hooff Date: Wed, 30 Oct 2019 10:54:22 +0100 Subject: [PATCH] Cleanup debugging things for cura-6874 CURA-6874 --- plugins/PreviewStage/PreviewMain.qml | 11 ++--------- .../SimulationView/SimulationViewMainComponent.qml | 14 +++++++------- resources/qml/Cura.qml | 5 ++--- 3 files changed, 11 insertions(+), 19 deletions(-) diff --git a/plugins/PreviewStage/PreviewMain.qml b/plugins/PreviewStage/PreviewMain.qml index 719b5c0c0b..9eac1b9d40 100644 --- a/plugins/PreviewStage/PreviewMain.qml +++ b/plugins/PreviewStage/PreviewMain.qml @@ -17,21 +17,14 @@ Item property var safeArea: parent // Subtract the actionPanel from the safe area. This way the view won't draw interface elements under/over it - Rectangle + Item { id: childSafeArea x: safeArea.x - parent.x y: safeArea.y - parent.y width: actionPanelWidget.x - x height: actionPanelWidget.y - y - visible: false // true for debug only - color:"#800000FF" - - Component.onCompleted: { - print("parent", parent.x, parent.y) - print("parent safe", safeArea.x, safeArea.y) - print("previewmain safe", childSafeArea.x, childSafeArea.y, childSafeArea.width, childSafeArea.height) - } + visible: false } Loader diff --git a/plugins/SimulationView/SimulationViewMainComponent.qml b/plugins/SimulationView/SimulationViewMainComponent.qml index 0cd2027dfa..3b70c69e82 100644 --- a/plugins/SimulationView/SimulationViewMainComponent.qml +++ b/plugins/SimulationView/SimulationViewMainComponent.qml @@ -18,10 +18,10 @@ Item property bool isSimulationPlaying: false - readonly property var layerSliderSafeYMin: safeArea.y - readonly property var layerSliderSafeYMax: safeArea.y + safeArea.height - readonly property var pathSliderSafeXMin: safeArea.x + playButton.width //todo playbutton margin or group button + slider in an item? - readonly property var pathSliderSafeXMax: safeArea.x + safeArea.width + readonly property real layerSliderSafeYMin: safeArea.y + readonly property real layerSliderSafeYMax: safeArea.y + safeArea.height + readonly property real pathSliderSafeXMin: safeArea.x + playButton.width + readonly property real pathSliderSafeXMax: safeArea.x + safeArea.width visible: UM.SimulationView.layerActivity && CuraApplication.platformActivity @@ -30,9 +30,9 @@ Item { id: pathSlider - readonly property var preferredWidth: UM.Theme.getSize("slider_layerview_size").height // not a typo, should be as long as layerview slider - readonly property var margin: UM.Theme.getSize("default_margin").width - readonly property var pathSliderSafeWidth: pathSliderSafeXMax - pathSliderSafeXMin + readonly property real preferredWidth: UM.Theme.getSize("slider_layerview_size").height // not a typo, should be as long as layerview slider + readonly property real margin: UM.Theme.getSize("default_margin").width + readonly property real pathSliderSafeWidth: pathSliderSafeXMax - pathSliderSafeXMin height: UM.Theme.getSize("slider_handle").width width: preferredWidth + margin * 2 < pathSliderSafeWidth ? preferredWidth : pathSliderSafeWidth - margin * 2 diff --git a/resources/qml/Cura.qml b/resources/qml/Cura.qml index 1f7ccf39a5..abae84e7f0 100644 --- a/resources/qml/Cura.qml +++ b/resources/qml/Cura.qml @@ -302,14 +302,13 @@ UM.MainWindow } // A hint for the loaded content view. Overlay items / controls can safely be placed in this area - Rectangle { + Item { id: mainSafeArea anchors.left: viewOrientationControls.right anchors.right: main.right anchors.top: main.top anchors.bottom: main.bottom - visible: false // set to true for debugging only - color:"#8000FF00" + visible: false } Loader