Rename method; fix index out of bounds exception
This commit is contained in:
parent
09678d4d7a
commit
74572b3772
2 changed files with 6 additions and 3 deletions
|
@ -210,6 +210,9 @@ public class PlanRouteFragment extends Fragment implements OsmAndLocationListene
|
|||
@Override
|
||||
public void onItemClick(View view) {
|
||||
int pos = markersRv.getChildAdapterPosition(view);
|
||||
if (pos == RecyclerView.NO_POSITION) {
|
||||
return;
|
||||
}
|
||||
if (pos == 0) {
|
||||
markersHelper.setStartFromMyLocation(!mapActivity.getMyApplication().getSettings().ROUTE_MAP_MARKERS_START_MY_LOC.get());
|
||||
} else {
|
||||
|
@ -358,7 +361,7 @@ public class PlanRouteFragment extends Fragment implements OsmAndLocationListene
|
|||
private MapActivity mapActivity = getMapActivity();
|
||||
|
||||
@Override
|
||||
public void doorByDoorOnClick() {
|
||||
public void doorToDoorOnClick() {
|
||||
if (mapActivity != null) {
|
||||
Toast.makeText(mapActivity, "Door to Door", Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
|
|
|
@ -56,7 +56,7 @@ public class PlanRouteSortByBottomSheetDialogFragment extends BottomSheetDialogF
|
|||
@Override
|
||||
public void onClick(View view) {
|
||||
if (listener != null) {
|
||||
listener.doorByDoorOnClick();
|
||||
listener.doorToDoorOnClick();
|
||||
dismiss();
|
||||
}
|
||||
}
|
||||
|
@ -135,7 +135,7 @@ public class PlanRouteSortByBottomSheetDialogFragment extends BottomSheetDialogF
|
|||
|
||||
interface PlanRouteSortByFragmentListener {
|
||||
|
||||
void doorByDoorOnClick();
|
||||
void doorToDoorOnClick();
|
||||
|
||||
void reverseOrderOnClick();
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue