use of net.osmand.plus.routepreparationmenu.RoutingOptionsHelper.RouteSimulationItem in project Osmand by osmandapp.
the class RouteOptionsBottomSheet method createMenuItems.
@Override
public void createMenuItems(Bundle savedInstanceState) {
items.add(new TitleItem(app.getString(R.string.shared_string_settings), ColorUtilities.getActiveColorId(nightMode)));
OsmAndAppCustomization customization = app.getAppCustomization();
List<LocalRoutingParameter> list = getRoutingParameters(applicationMode);
for (final LocalRoutingParameter optionsItem : list) {
if (!dialogMode.isAvailableParameter(optionsItem) || !customization.isFeatureEnabled(optionsItem.getKey())) {
continue;
}
if (optionsItem instanceof DividerItem) {
if (isDividerRequired()) {
items.add(new DividerStartItem(app));
}
} else if (optionsItem instanceof MuteSoundRoutingParameter) {
items.add(createMuteSoundItem(optionsItem));
} else if (optionsItem instanceof ShowAlongTheRouteItem) {
items.add(createShowAlongTheRouteItem(optionsItem));
} else if (optionsItem instanceof RouteSimulationItem) {
items.add(createRouteSimulationItem(optionsItem));
} else if (optionsItem instanceof AvoidPTTypesRoutingParameter) {
items.add(createAvoidPTTypesItem(optionsItem));
} else if (optionsItem instanceof AvoidRoadsRoutingParameter) {
items.add(createAvoidRoadsItem(optionsItem));
} else if (optionsItem instanceof GpxLocalRoutingParameter) {
items.add(createGpxRoutingItem(optionsItem));
} else if (optionsItem instanceof TimeConditionalRoutingItem) {
items.add(createTimeConditionalRoutingItem(optionsItem));
} else if (optionsItem instanceof OtherSettingsRoutingParameter) {
items.add(createOtherSettingsRoutingItem(optionsItem));
} else if (optionsItem instanceof CustomizeRouteLineRoutingParameter) {
items.add(createCustomizeRouteLineRoutingItem(optionsItem));
} else if (USE_HEIGHT_OBSTACLES.equals(optionsItem.getKey()) && hasReliefParameters()) {
items.add(inflateElevationParameter(optionsItem));
} else {
inflateRoutingParameter(optionsItem);
}
}
}
Aggregations