From ba73f2a9f51e781a17ec2e237cfd90213769b6a0 Mon Sep 17 00:00:00 2001 From: Julien Olivain Date: Sat, 2 Oct 2021 19:34:10 +0200 Subject: [PATCH] FlightDisplay: put zoom buttons on the left of the scale The map scale width changes when the zoom up/down buttons are clicked. When buttons are on the right, and when the user quickly clicks a zoom up/down button several times, the first click change the scale, which changes the buttons position. Subsequent clicks are most of the time not where the user wanted to put them. Putting buttons on the left of the scale will keep them at a fixed position, fixing this unfortunate behavior. Signed-off-by: Julien Olivain --- src/FlightDisplay/FlyViewMap.qml | 2 +- src/FlightDisplay/FlyViewWidgetLayer.qml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/FlightDisplay/FlyViewMap.qml b/src/FlightDisplay/FlyViewMap.qml index 1396874..c3e3fbf 100644 --- a/src/FlightDisplay/FlyViewMap.qml +++ b/src/FlightDisplay/FlyViewMap.qml @@ -646,7 +646,7 @@ FlightMap { anchors.left: parent.left anchors.top: parent.top mapControl: _root - buttonsOnLeft: false + buttonsOnLeft: true visible: !ScreenTools.isTinyScreen && QGroundControl.corePlugin.options.flyView.showMapScale && mapControl.pipState.state === mapControl.pipState.windowState property real centerInset: visible ? parent.height - y : 0 diff --git a/src/FlightDisplay/FlyViewWidgetLayer.qml b/src/FlightDisplay/FlyViewWidgetLayer.qml index 8f4fbea..79b8e8d 100644 --- a/src/FlightDisplay/FlyViewWidgetLayer.qml +++ b/src/FlightDisplay/FlyViewWidgetLayer.qml @@ -300,7 +300,7 @@ Item { anchors.left: toolStrip.right anchors.top: parent.top mapControl: _mapControl - buttonsOnLeft: false + buttonsOnLeft: true visible: !ScreenTools.isTinyScreen && QGroundControl.corePlugin.options.flyView.showMapScale && mapControl.pipState.state === mapControl.pipState.fullState property real topEdgeCenterInset: visible ? y + height : 0