Fix clear points command
This commit is contained in:
parent
b6893b4b46
commit
fe196a0f67
2 changed files with 1 additions and 1 deletions
|
@ -595,7 +595,6 @@ public class MeasurementToolFragment extends Fragment {
|
|||
@Override
|
||||
public void clearAllOnClick() {
|
||||
editingCtx.getCommandManager().execute(new ClearPointsCommand(measurementLayer));
|
||||
editingCtx.clearSegments();
|
||||
editingCtx.cancelSnapToRoad();
|
||||
if (pointsListOpened) {
|
||||
hidePointsList();
|
||||
|
|
|
@ -19,6 +19,7 @@ public class ClearPointsCommand extends MeasurementModeCommand {
|
|||
List<WptPt> pts = measurementLayer.getEditingCtx().getPoints();
|
||||
points = new LinkedList<>(pts);
|
||||
pts.clear();
|
||||
measurementLayer.getEditingCtx().clearSegments();
|
||||
measurementLayer.refreshMap();
|
||||
return true;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue