Fix possible crash
This commit is contained in:
parent
75b28b224d
commit
e57db2bfc2
1 changed files with 3 additions and 2 deletions
|
@ -1103,8 +1103,9 @@ public class MapRouteInfoMenu implements IRouteInformationListener {
|
|||
}
|
||||
|
||||
public void selectMapMarker(final int index, final PointType pointType) {
|
||||
if (index != -1) {
|
||||
MapMarker m = mapActivity.getMyApplication().getMapMarkersHelper().getMapMarkers().get(index);
|
||||
List<MapMarker> mapMarkers = mapActivity.getMyApplication().getMapMarkersHelper().getMapMarkers();
|
||||
if (index != -1 && mapMarkers.size() > index) {
|
||||
MapMarker m = mapMarkers.get(index);
|
||||
LatLon point = new LatLon(m.getLatitude(), m.getLongitude());
|
||||
TargetPointsHelper targets = getTargets();
|
||||
switch (pointType) {
|
||||
|
|
Loading…
Reference in a new issue