diff --git a/OsmAnd/res/layout-land/fragment_coordinate_input_dialog.xml b/OsmAnd/res/layout-land/fragment_coordinate_input_dialog.xml
index 3e80714dbf..6ae140aa0a 100644
--- a/OsmAnd/res/layout-land/fragment_coordinate_input_dialog.xml
+++ b/OsmAnd/res/layout-land/fragment_coordinate_input_dialog.xml
@@ -37,6 +37,12 @@
android:layout_marginRight="16dp"
android:layout_marginEnd="16dp"/>
+
+
+
+
0 ? mapMarkers.get(mapMarkers.size() - 1).colorIndex : -1;
+ if (colorIndex == -1) {
+ colorIndex = 0;
+ } else {
+ colorIndex = (colorIndex + 1) % MAP_MARKERS_COLORS_COUNT;
+ }
+ MapMarker mapMarker = new MapMarker(latLon, pointDescription, colorIndex, false, 0);
+ mapMarker.history = false;
+ mapMarker.nextKey = MapMarkersDbHelper.TAIL_NEXT_VALUE;
+ mapMarkers.add(mapMarker);
+ adapter.notifyDataSetChanged();
+ }
+
private MapActivity getMapActivity() {
return (MapActivity) getActivity();
}
diff --git a/OsmAnd/src/net/osmand/plus/mapmarkers/adapters/CoordinateInputAdapter.java b/OsmAnd/src/net/osmand/plus/mapmarkers/adapters/CoordinateInputAdapter.java
index 77e8cc44bc..88a80266b2 100644
--- a/OsmAnd/src/net/osmand/plus/mapmarkers/adapters/CoordinateInputAdapter.java
+++ b/OsmAnd/src/net/osmand/plus/mapmarkers/adapters/CoordinateInputAdapter.java
@@ -7,19 +7,15 @@ import android.view.View;
import android.view.ViewGroup;
import net.osmand.data.LatLon;
-import net.osmand.data.PointDescription;
import net.osmand.plus.IconsCache;
import net.osmand.plus.MapMarkersHelper.MapMarker;
import net.osmand.plus.R;
import net.osmand.plus.activities.MapActivity;
import net.osmand.plus.dashboard.DashLocationFragment;
import net.osmand.plus.helpers.AndroidUiHelper;
-import net.osmand.plus.mapmarkers.MapMarkersDbHelper;
import java.util.List;
-import static net.osmand.plus.MapMarkersHelper.MAP_MARKERS_COLORS_COUNT;
-
public class CoordinateInputAdapter extends RecyclerView.Adapter {
private MapActivity mapActivity;
@@ -118,19 +114,4 @@ public class CoordinateInputAdapter extends RecyclerView.Adapter 0 ? mapMarkers.get(mapMarkers.size() - 1).colorIndex : -1;
- if (colorIndex == -1) {
- colorIndex = 0;
- } else {
- colorIndex = (colorIndex + 1) % MAP_MARKERS_COLORS_COUNT;
- }
- MapMarker mapMarker = new MapMarker(latLon, pointDescription, colorIndex, false, 0);
- mapMarker.history = false;
- mapMarker.nextKey = MapMarkersDbHelper.TAIL_NEXT_VALUE;
- mapMarkers.add(mapMarker);
- notifyDataSetChanged();
- }
}