diff --git a/OsmAnd/src/net/osmand/plus/activities/MapActivity.java b/OsmAnd/src/net/osmand/plus/activities/MapActivity.java index 17e6fd9dae..1a57a5156a 100644 --- a/OsmAnd/src/net/osmand/plus/activities/MapActivity.java +++ b/OsmAnd/src/net/osmand/plus/activities/MapActivity.java @@ -28,7 +28,8 @@ import net.osmand.plus.PoiFilter; import net.osmand.plus.R; import net.osmand.plus.TargetPointsHelper; import net.osmand.plus.Version; -import net.osmand.plus.activities.MapActivityActions.DirectionDialogStyle; +import net.osmand.plus.activities.actions.NavigateAction; +import net.osmand.plus.activities.actions.NavigateAction.DirectionDialogStyle; import net.osmand.plus.activities.search.SearchActivity; import net.osmand.plus.base.FailSafeFuntions; import net.osmand.plus.base.MapViewTrackingUtilities; @@ -308,7 +309,7 @@ public class MapActivity extends AccessibleActivity { Location loc = new Location("map"); loc.setLatitude(mapView.getLatitude()); loc.setLongitude(mapView.getLongitude()); - mapActions.getDirections(loc, null, DirectionDialogStyle.create()); + new NavigateAction(this).getDirections(loc, null, DirectionDialogStyle.create()); } if(mapLabelToShow != null && latLonToShow != null){ mapLayers.getContextMenuLayer().setSelectedObject(toShow); diff --git a/OsmAnd/src/net/osmand/plus/activities/SettingsBaseActivity.java b/OsmAnd/src/net/osmand/plus/activities/SettingsBaseActivity.java index b4bf35dbd9..4d9fcf272b 100644 --- a/OsmAnd/src/net/osmand/plus/activities/SettingsBaseActivity.java +++ b/OsmAnd/src/net/osmand/plus/activities/SettingsBaseActivity.java @@ -15,6 +15,7 @@ import net.osmand.plus.OsmandApplication; import net.osmand.plus.OsmandSettings; import net.osmand.plus.OsmandSettings.OsmandPreference; import net.osmand.plus.R; +import net.osmand.plus.activities.actions.NavigateAction; import net.osmand.plus.views.SeekBarPreference; import android.app.ActionBar; import android.app.AlertDialog; @@ -305,7 +306,7 @@ public abstract class SettingsBaseActivity extends SherlockPreferenceActivity im protected void profileDialog() { Builder b = new AlertDialog.Builder(this); final Set selected = new LinkedHashSet(); - View v = MapActivityActions.prepareAppModeView(this, selected, false, null, + View v = NavigateAction.prepareAppModeView(this, selected, false, null, new View.OnClickListener() { @Override public void onClick(View v) { diff --git a/OsmAnd/src/net/osmand/plus/views/MapInfoLayer.java b/OsmAnd/src/net/osmand/plus/views/MapInfoLayer.java index 8e3d4bcfee..a8663dbcc0 100644 --- a/OsmAnd/src/net/osmand/plus/views/MapInfoLayer.java +++ b/OsmAnd/src/net/osmand/plus/views/MapInfoLayer.java @@ -13,7 +13,7 @@ import net.osmand.plus.OsmandApplication; import net.osmand.plus.OsmandSettings; import net.osmand.plus.R; import net.osmand.plus.activities.MapActivity; -import net.osmand.plus.activities.MapActivityActions; +import net.osmand.plus.activities.actions.NavigateAction; import net.osmand.plus.routing.RoutingHelper; import net.osmand.plus.views.mapwidgets.AppearanceWidgetsFactory; import net.osmand.plus.views.mapwidgets.BaseMapWidget; @@ -423,7 +423,7 @@ public class MapInfoLayer extends OsmandMapLayer { Builder b = new AlertDialog.Builder(map); View confirmDialog = view.inflate(view.getContext(), R.layout.configuration_dialog, null); final ListView lv = (ListView) confirmDialog.findViewById(android.R.id.list); - MapActivityActions.prepareAppModeView(map, selected, true, + NavigateAction.prepareAppModeView(map, selected, true, (ViewGroup) confirmDialog.findViewById(R.id.TopBar), new View.OnClickListener() { @Override