icon color list adapter fix

This commit is contained in:
madwasp79 2019-06-18 18:58:13 +03:00
parent 765ae42e5b
commit 24d51ba07a
4 changed files with 4 additions and 4 deletions

View file

@ -865,7 +865,7 @@ public class EditProfileFragment extends BaseOsmAndFragment {
app.getUIUtilities().getThemedIcon(R.drawable.ic_action_circle), null);
} else {
textView.setCompoundDrawablesWithIntrinsicBounds(null, null,
app.getUIUtilities().getPaintedIcon(R.drawable.ic_action_circle, item.color), null);
app.getUIUtilities().getIcon(R.drawable.ic_action_circle, item.color), null);
}
textView.setCompoundDrawablePadding(AndroidUtils.dpToPx(getContext(), 10f));

View file

@ -139,7 +139,7 @@ public class ProfileMenuAdapter extends RecyclerView.Adapter<ProfileViewHolder>
}
private void updateViewHolder(ProfileViewHolder holder, ApplicationMode mode) {
int iconRes = mode.getParent() == null ? mode.getSmallIconDark() : mode.getIconRes(app);
int iconRes = mode.getIconRes(app);
if (iconRes == 0 || iconRes == -1) {
iconRes = R.drawable.ic_action_world_globe;
}

View file

@ -83,7 +83,7 @@ public class NavStartStopAction extends QuickAction {
if (context instanceof MapActivity) {
RoutingHelper helper = ((MapActivity) context).getRoutingHelper();
if (!helper.isRoutePlanningMode() && !helper.isFollowingMode()) {
return ((MapActivity) context).getMapActions().getRouteMode(null).getSmallIconDark();
return ((MapActivity) context).getMapActions().getRouteMode(null).getIconRes(context);
}
return helper.getAppMode().getIconRes(context);
}

View file

@ -780,7 +780,7 @@ public class MapControlsLayer extends OsmandMapLayer {
compassHud.forceHideCompass = forceHideCompass;
compassHud.updateVisibility(!forceHideCompass && shouldShowCompass());
if (layersHud.setIconResId(settings.getApplicationMode().getMapIconId())) {
if (layersHud.setIconResId(settings.getApplicationMode().getIconRes(app))) {
layersHud.update(app, isNight);
}
layersHud.updateVisibility(!routeDialogOpened && !trackDialogOpened && !isInMeasurementToolMode() && !isInPlanRouteMode()