Fix issue

This commit is contained in:
Victor Shcherb 2015-04-02 01:51:05 +02:00
parent a233194807
commit 39bae9a466
3 changed files with 13 additions and 1 deletions

View file

@ -0,0 +1,9 @@
<?xml version="1.0" encoding="utf-8"?>
<View xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:id="@+id/divider"
android:layout_width="match_parent"
android:layout_height="1dp"
android:background="?attr/dashboard_divider"
android:focusable="false"
android:visibility="gone" />

View file

@ -71,6 +71,7 @@ public class DashWaypointsFragment extends DashLocationFragment {
} }
((TextView) mainView.findViewById(R.id.fav_text)).setText(getString(R.string.waypoints)); ((TextView) mainView.findViewById(R.id.fav_text)).setText(getString(R.string.waypoints));
((Button) mainView.findViewById(R.id.show_all)).setText(getString(R.string.shared_string_show_all)); ((Button) mainView.findViewById(R.id.show_all)).setText(getString(R.string.shared_string_show_all));
((Button) mainView.findViewById(R.id.show_all)).setVisibility(View.VISIBLE);
((Button) mainView.findViewById(R.id.show_all)).setOnClickListener(new View.OnClickListener() { ((Button) mainView.findViewById(R.id.show_all)).setOnClickListener(new View.OnClickListener() {
@Override @Override
@ -83,6 +84,8 @@ public class DashWaypointsFragment extends DashLocationFragment {
List<DashLocationView> distances = new ArrayList<DashLocationFragment.DashLocationView>(); List<DashLocationView> distances = new ArrayList<DashLocationFragment.DashLocationView>();
for(int i = 0; i < 3 && i < allPoints.size(); i++) { for(int i = 0; i < 3 && i < allPoints.size(); i++) {
LocationPointWrapper ps = allPoints.get(i); LocationPointWrapper ps = allPoints.get(i);
View dv = getActivity().getLayoutInflater().inflate(R.layout.divider, null);
favorites.addView(dv);
View v = WaypointDialogHelper.updateWaypointItemView(false, null, getMyApplication(), getActivity(), null, ps, null); View v = WaypointDialogHelper.updateWaypointItemView(false, null, getMyApplication(), getActivity(), null, ps, null);
favorites.addView(v); favorites.addView(v);

View file

@ -235,7 +235,7 @@ public class MapRoutePreferencesControl {
} }
GeneralRouter rm = SettingsNavigationActivity.getRouter(mapActivity.getMyApplication() GeneralRouter rm = SettingsNavigationActivity.getRouter(mapActivity.getMyApplication()
.getDefaultRoutingConfig(), am); .getDefaultRoutingConfig(), am);
if (rm == null || (rparams != null && !rparams.isCalculateOsmAndRoute())) { if (rm == null || (rparams != null && !rparams.isCalculateOsmAndRoute()) && !rparams.getFile().hasRtePt()) {
return list; return list;
} }
for (RoutingParameter r : rm.getParameters().values()) { for (RoutingParameter r : rm.getParameters().values()) {