From 698907bc98121fe0408baa39eb42ccfb0abee571 Mon Sep 17 00:00:00 2001 From: Alexey Kulish Date: Sun, 12 Mar 2017 12:37:32 +0300 Subject: [PATCH] Hide slope axis if no data --- OsmAnd/src/net/osmand/plus/helpers/GpxUiHelper.java | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/OsmAnd/src/net/osmand/plus/helpers/GpxUiHelper.java b/OsmAnd/src/net/osmand/plus/helpers/GpxUiHelper.java index 90a2dfab99..b89b59eb6d 100644 --- a/OsmAnd/src/net/osmand/plus/helpers/GpxUiHelper.java +++ b/OsmAnd/src/net/osmand/plus/helpers/GpxUiHelper.java @@ -1373,6 +1373,9 @@ public class GpxUiHelper { } if (values == null) { + if (useRightAxis) { + yAxis.setEnabled(false); + } return null; } @@ -1398,6 +1401,9 @@ public class GpxUiHelper { double SLOPE_PROXIMITY = 150; if (totalDistance - SLOPE_PROXIMITY < 0) { + if (useRightAxis) { + yAxis.setEnabled(false); + } return null; }