diff --git a/OsmAnd/src/net/osmand/plus/activities/MapActivity.java b/OsmAnd/src/net/osmand/plus/activities/MapActivity.java index e43df10182..5029409ced 100644 --- a/OsmAnd/src/net/osmand/plus/activities/MapActivity.java +++ b/OsmAnd/src/net/osmand/plus/activities/MapActivity.java @@ -114,6 +114,7 @@ import net.osmand.plus.measurementtool.MeasurementEditingContext; import net.osmand.plus.measurementtool.MeasurementToolFragment; import net.osmand.plus.measurementtool.NewGpxData; import net.osmand.plus.profiles.EditProfileFragment; +import net.osmand.plus.quickaction.QuickActionListFragment; import net.osmand.plus.render.RendererRegistry; import net.osmand.plus.resources.ResourceManager; import net.osmand.plus.routepreparationmenu.ChooseRouteFragment; @@ -682,8 +683,13 @@ public class MapActivity extends OsmandActionBarActivity implements DownloadEven prevActivityIntent = null; return; } - if (getMapView().getLayerByClass(MapQuickActionLayer.class).onBackPressed()) + if (getMapView().getLayerByClass(MapQuickActionLayer.class).onBackPressed()) { return; + } + QuickActionListFragment quickActionListFragment = getQuickActionListFragment(); + if ( quickActionListFragment!=null && quickActionListFragment.isVisible()) { + this.getDashboard().setDashboardVisibility(true, DashboardType.CONFIGURE_SCREEN, null); + } super.onBackPressed(); } @@ -2281,6 +2287,11 @@ public class MapActivity extends OsmandActionBarActivity implements DownloadEven return fragment != null && !fragment.isDetached() && !fragment.isRemoving() ? (EditProfileFragment) fragment : null; } + public QuickActionListFragment getQuickActionListFragment() { + Fragment fragment = getSupportFragmentManager().findFragmentByTag(QuickActionListFragment.TAG); + return fragment != null && !fragment.isDetached() && !fragment.isRemoving() ? (QuickActionListFragment) fragment : null; + } + public boolean isTopToolbarActive() { MapInfoLayer mapInfoLayer = getMapLayers().getMapInfoLayer(); return mapInfoLayer.hasTopToolbar();