fix - add colors to profiles in Measurement tool's Snap to road mode

This commit is contained in:
madwasp79 2019-06-26 14:14:39 +03:00
parent 95403f361a
commit 34d208c3a1
2 changed files with 2 additions and 2 deletions

View file

@ -805,7 +805,7 @@ public class MeasurementToolFragment extends BaseOsmAndFragment {
ImageButton snapToRoadBtn = (ImageButton) mapActivity.findViewById(R.id.snap_to_road_image_button); ImageButton snapToRoadBtn = (ImageButton) mapActivity.findViewById(R.id.snap_to_road_image_button);
snapToRoadBtn.setBackgroundResource(nightMode ? R.drawable.btn_circle_night : R.drawable.btn_circle); snapToRoadBtn.setBackgroundResource(nightMode ? R.drawable.btn_circle_night : R.drawable.btn_circle);
snapToRoadBtn.setImageDrawable(getActiveIcon(appMode.getIconRes())); snapToRoadBtn.setImageDrawable(getIcon(appMode.getIconRes(), appMode.getIconColorInfo().getColor(nightMode)));
snapToRoadBtn.setOnClickListener(new View.OnClickListener() { snapToRoadBtn.setOnClickListener(new View.OnClickListener() {
@Override @Override
public void onClick(View view) { public void onClick(View view) {

View file

@ -96,7 +96,7 @@ public class SnapToRoadBottomSheetDialogFragment extends android.support.design.
ApplicationMode mode = modes.get(i); ApplicationMode mode = modes.get(i);
View row = View.inflate(new ContextThemeWrapper(getContext(), themeRes), R.layout.list_item_icon_and_title, null); View row = View.inflate(new ContextThemeWrapper(getContext(), themeRes), R.layout.list_item_icon_and_title, null);
((ImageView) row.findViewById(R.id.icon)).setImageDrawable( ((ImageView) row.findViewById(R.id.icon)).setImageDrawable(
getContentIcon(mode.getIconRes())); app.getUIUtilities().getIcon(mode.getIconRes(), mode.getIconColorInfo().getColor(nightMode)));
((TextView) row.findViewById(R.id.title)).setText(mode.toHumanString(getContext())); ((TextView) row.findViewById(R.id.title)).setText(mode.toHumanString(getContext()));
row.setOnClickListener(onClickListener); row.setOnClickListener(onClickListener);
row.setTag(i); row.setTag(i);