Keep Navigation controls (Start/pause/continue/stop) together in menu

This commit is contained in:
sonora 2014-08-20 21:09:18 +02:00
parent 0f8aad4060
commit 3b59b52f42

View file

@ -829,19 +829,6 @@ public class MapActivityActions implements DialogProvider {
}
}).reg();
}
if (getTargets().getPointToNavigate() != null) {
optionsMenuHelper.item(R.string.target_points).icons(R.drawable.ic_action_flage_dark, R.drawable.ic_action_flage_light)
.listen(new OnContextMenuClick() {
@Override
public void onContextMenuClick(int itemId, int pos, boolean isChecked, DialogInterface dialog) {
if (getMyApplication().getWaypointHelper().isRouteCalculated()) {
WaypointDialogHelper.showWaypointsDialog(getMyApplication(), mapActivity);
} else {
openIntermediatePointsDialog();
}
}
}).reg();
}
if (mapActivity.getPointToNavigate() != null) {
int nav;
if(routingHelper.isFollowingMode()) {
@ -859,6 +846,19 @@ public class MapActivityActions implements DialogProvider {
}
}).reg();
}
if (getTargets().getPointToNavigate() != null) {
optionsMenuHelper.item(R.string.target_points).icons(R.drawable.ic_action_flage_dark, R.drawable.ic_action_flage_light)
.listen(new OnContextMenuClick() {
@Override
public void onContextMenuClick(int itemId, int pos, boolean isChecked, DialogInterface dialog) {
if (getMyApplication().getWaypointHelper().isRouteCalculated()) {
WaypointDialogHelper.showWaypointsDialog(getMyApplication(), mapActivity);
} else {
openIntermediatePointsDialog();
}
}
}).reg();
}
// 5-9. Default actions (Layers, Configure Map screen, Settings, Search, Favorites)
optionsMenuHelper.item(R.string.menu_layers).icons(R.drawable.ic_action_layers_dark, R.drawable.ic_action_layers_light)