Add description to some route parameters
This commit is contained in:
parent
eb3ecabf53
commit
ebe4057f68
4 changed files with 14 additions and 6 deletions
|
@ -12,6 +12,12 @@
|
|||
|
||||
-->
|
||||
|
||||
<string name="elevation_data_descr">Routing could avoid strong uphills</string>
|
||||
<string name="map_orientation_threshold_descr">Don\'t rotate map view if speed is less than a threshold</string>
|
||||
<string name="snap_to_road_descr">Current location icon will be snapped to the current navigation route</string>
|
||||
<string name="routing_attr_driving_style_description">Select driving purpose to get shorter, faster or safer route</string>
|
||||
<string name="routing_attr_short_way_description">Optimized shorter route (energy saving)</string>
|
||||
<string name="temporary_conditional_routing_descr">Use road restrictions that are active now on the map</string>
|
||||
<string name="login_open_place_reviews">Login to OpenPlaceReviews</string>
|
||||
<string name="opr_use_dev_url">Use test.openplacereviews.org</string>
|
||||
<string name="open_place_reviews">OpenPlaceReviews</string>
|
||||
|
@ -104,7 +110,6 @@
|
|||
<string name="plan_route_split_before">Split before</string>
|
||||
<string name="plan_route_join_segments">Join segments</string>
|
||||
<string name="app_mode_light_aircraft">Light aircraft</string>
|
||||
<string name="elevation_data">You can use elevation data to account for ascent/descent of your trip</string>
|
||||
<string name="ltr_or_rtl_combine_via_star">%1$s * %2$s</string>
|
||||
<string name="add_photos_descr">OsmAnd shows photos from several sources:\nOpenPlaceReviews - POI photos;\nMapillary - street-level imagery;\nWeb / Wikimedia - POI photos as per OpenStreetMap data.</string>
|
||||
<string name="use_dev_url">Use dev.openstreetmap.org</string>
|
||||
|
@ -1731,7 +1736,6 @@
|
|||
<string name="update_all_maps_now">Update all maps now?</string>
|
||||
<string name="clear_tile_data">Clear all tiles</string>
|
||||
<string name="routing_attr_short_way_name">Fuel-efficient way</string>
|
||||
<string name="routing_attr_short_way_description">Use fuel-efficient way (usually shorter).</string>
|
||||
<string name="replace_favorite_confirmation">Are you sure you want to replace Favorite %1$s?</string>
|
||||
<string name="rendering_attr_hideOverground_name">Overground objects</string>
|
||||
<string name="shared_string_change">Change</string>
|
||||
|
@ -2895,7 +2899,6 @@
|
|||
<string name="avoid_motorway">No motorways</string>
|
||||
<string name="auto_zoom_map_descr">Zoom level according to your speed (while map is synchronized with current position).</string>
|
||||
<string name="auto_zoom_map">Auto zoom map</string>
|
||||
<string name="snap_to_road_descr">Snap position to roads during navigation.</string>
|
||||
<string name="snap_to_road">Snap to road</string>
|
||||
<string name="interrupt_music_descr">Voice prompts pause music playback.</string>
|
||||
<string name="interrupt_music">Pause music</string>
|
||||
|
|
|
@ -18,7 +18,7 @@ import net.osmand.plus.base.MenuBottomSheetDialogFragment;
|
|||
import net.osmand.plus.base.bottomsheetmenu.BaseBottomSheetItem;
|
||||
import net.osmand.plus.base.bottomsheetmenu.BottomSheetItemWithCompoundButton;
|
||||
import net.osmand.plus.base.bottomsheetmenu.simpleitems.DividerSpaceItem;
|
||||
import net.osmand.plus.base.bottomsheetmenu.simpleitems.LongDescriptionItem;
|
||||
import net.osmand.plus.base.bottomsheetmenu.simpleitems.ShortDescriptionItem;
|
||||
import net.osmand.plus.base.bottomsheetmenu.simpleitems.TitleItem;
|
||||
import net.osmand.plus.routepreparationmenu.RouteOptionsBottomSheet;
|
||||
import net.osmand.plus.settings.backend.ApplicationMode;
|
||||
|
@ -114,8 +114,7 @@ public class ElevationDateBottomSheet extends MenuBottomSheetDialogFragment {
|
|||
|
||||
int contentPaddingSmall = getResources().getDimensionPixelSize(R.dimen.content_padding_small);
|
||||
items.add(new DividerSpaceItem(app, contentPaddingSmall));
|
||||
items.add(new LongDescriptionItem(getString(R.string.elevation_data)));
|
||||
items.add(new DividerSpaceItem(app, contentPaddingSmall));
|
||||
items.add(new ShortDescriptionItem((getString(R.string.elevation_data_descr))));
|
||||
|
||||
createReliefFactorButtons(themedCtx);
|
||||
}
|
||||
|
|
|
@ -90,6 +90,7 @@ public class MapDuringNavigationFragment extends BaseSettingsFragment {
|
|||
}
|
||||
}
|
||||
ListPreferenceEx switchMapDirectionToCompass = (ListPreferenceEx) findPreference(settings.SWITCH_MAP_DIRECTION_TO_COMPASS_KMH.getId());
|
||||
switchMapDirectionToCompass.setDescription(R.string.map_orientation_threshold_descr);
|
||||
switchMapDirectionToCompass.setEntries(names);
|
||||
switchMapDirectionToCompass.setEntryValues(valuesKmh);
|
||||
}
|
||||
|
|
|
@ -156,6 +156,7 @@ public class RouteParametersFragment extends BaseSettingsFragment implements OnP
|
|||
timeConditionalRouting.setIcon(getRoutingPrefIcon(settings.ENABLE_TIME_CONDITIONAL_ROUTING.getId()));
|
||||
timeConditionalRouting.setSummaryOn(R.string.shared_string_on);
|
||||
timeConditionalRouting.setSummaryOff(R.string.shared_string_off);
|
||||
timeConditionalRouting.setDescription(R.string.temporary_conditional_routing_descr);
|
||||
getPreferenceScreen().addPreference(timeConditionalRouting);
|
||||
}
|
||||
|
||||
|
@ -580,6 +581,7 @@ public class RouteParametersFragment extends BaseSettingsFragment implements OnP
|
|||
private ListPreferenceEx createRoutingBooleanListPreference(String groupKey, List<RoutingParameter> routingParameters) {
|
||||
String defaultTitle = Algorithms.capitalizeFirstLetterAndLowercase(groupKey.replace('_', ' '));
|
||||
String title = AndroidUtils.getRoutingStringPropertyName(app, groupKey, defaultTitle);
|
||||
String description = AndroidUtils.getRoutingStringPropertyDescription(app, groupKey, "");
|
||||
ApplicationMode am = getSelectedAppMode();
|
||||
|
||||
Object[] entryValues = new Object[routingParameters.size()];
|
||||
|
@ -599,6 +601,9 @@ public class RouteParametersFragment extends BaseSettingsFragment implements OnP
|
|||
routingListPref.setPersistent(false);
|
||||
routingListPref.setValue(selectedParameterId);
|
||||
routingListPref.setIcon(getRoutingPrefIcon(groupKey));
|
||||
if (!Algorithms.isEmpty(defaultTitle)) {
|
||||
routingListPref.setDescription(description);
|
||||
}
|
||||
|
||||
return routingListPref;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue