From 388be5c3ef02fe744f2c07b0b3935822fd69d4ae Mon Sep 17 00:00:00 2001 From: androiddevkotlin <64539346+androiddevkotlin@users.noreply.github.com> Date: Thu, 8 Apr 2021 23:07:02 +0300 Subject: [PATCH] =?UTF-8?q?Hide=20widgets:=20Select=20track=20on=20the=20m?= =?UTF-8?q?ap,=20tap=20on=20the=20"Edit"=20button,=20"Plan=20route"=20will?= =?UTF-8?q?=20be=20opened,=20map=20widgets=20will=20be=20visible.=20If=20y?= =?UTF-8?q?ou=20open=20Menu=20=E2=80=93=20Plan=20Route=20=E2=80=93=20Selec?= =?UTF-8?q?t=20the=20same=20track,=20widgets=20would=20be=20visible.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- OsmAnd/src/net/osmand/plus/track/TrackMenuFragment.java | 2 +- .../plus/views/mapwidgets/WidgetsVisibilityHelper.java | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/OsmAnd/src/net/osmand/plus/track/TrackMenuFragment.java b/OsmAnd/src/net/osmand/plus/track/TrackMenuFragment.java index e1a620269d..ae32e57fef 100644 --- a/OsmAnd/src/net/osmand/plus/track/TrackMenuFragment.java +++ b/OsmAnd/src/net/osmand/plus/track/TrackMenuFragment.java @@ -841,9 +841,9 @@ public class TrackMenuFragment extends ContextMenuScrollFragment implements Card osmEditingPlugin.sendGPXFiles(mapActivity, this, gpxInfo); } } else if (buttonIndex == EDIT_BUTTON_INDEX) { + dismiss(); String fileName = Algorithms.getFileWithoutDirs(gpxFile.path); MeasurementToolFragment.showInstance(mapActivity.getSupportFragmentManager(), fileName); - dismiss(); } else if (buttonIndex == RENAME_BUTTON_INDEX) { FileUtils.renameFile(mapActivity, new File(gpxFile.path), this, true); } else if (buttonIndex == CHANGE_FOLDER_BUTTON_INDEX) { diff --git a/OsmAnd/src/net/osmand/plus/views/mapwidgets/WidgetsVisibilityHelper.java b/OsmAnd/src/net/osmand/plus/views/mapwidgets/WidgetsVisibilityHelper.java index fd2d873a29..72d8814a80 100644 --- a/OsmAnd/src/net/osmand/plus/views/mapwidgets/WidgetsVisibilityHelper.java +++ b/OsmAnd/src/net/osmand/plus/views/mapwidgets/WidgetsVisibilityHelper.java @@ -21,10 +21,10 @@ import java.lang.ref.WeakReference; public class WidgetsVisibilityHelper { - private MapActivity mapActivity; - private OsmandSettings settings; - private RoutingHelper routingHelper; - private MapActivityLayers mapLayers; + private final MapActivity mapActivity; + private final OsmandSettings settings; + private final RoutingHelper routingHelper; + private final MapActivityLayers mapLayers; public WidgetsVisibilityHelper(@NonNull MapActivity mapActivity) { this.mapActivity = mapActivity;