From b72678ddac554091bde1425a2f9c2fce853f1f3a Mon Sep 17 00:00:00 2001 From: Vitaliy Date: Fri, 14 Feb 2020 18:37:17 +0200 Subject: [PATCH] Fix custom parent ui --- .../osmand/plus/settings/ProfileAppearanceFragment.java | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/OsmAnd/src/net/osmand/plus/settings/ProfileAppearanceFragment.java b/OsmAnd/src/net/osmand/plus/settings/ProfileAppearanceFragment.java index c2c4f25439..8c950fea45 100644 --- a/OsmAnd/src/net/osmand/plus/settings/ProfileAppearanceFragment.java +++ b/OsmAnd/src/net/osmand/plus/settings/ProfileAppearanceFragment.java @@ -634,11 +634,8 @@ public class ProfileAppearanceFragment extends BaseSettingsFragment { } private void setupBaseProfileView(String stringKey) { - for (ApplicationMode am : ApplicationMode.getDefaultValues()) { - if (am.getStringKey().equals(stringKey)) { - baseProfileName.setText(Algorithms.capitalizeFirstLetter(am.toHumanString())); - } - } + ApplicationMode mode = ApplicationMode.valueOfStringKey(stringKey, ApplicationMode.DEFAULT); + baseProfileName.setText(Algorithms.capitalizeFirstLetter(mode.toHumanString())); } private boolean saveProfile() {