Set icon space reserved as default for created preferences
This commit is contained in:
parent
fd8d4be6ee
commit
1430fed7c7
4 changed files with 6 additions and 8 deletions
|
@ -3443,7 +3443,7 @@ Ha szereted az OsmAndot és az OSM-et, és szeretnéd támogatni a fejlődésük
|
|||
<string name="login_and_pass">Felhasználónév és jelszó</string>
|
||||
<string name="plugin_global_prefs_info">Ezek a bővítménybeállítások globálisak, és minden profilra vonatkoznak.</string>
|
||||
<string name="osm_editing">OpenStreetMap-szerkesztés</string>
|
||||
<string name="osm_edits_view_descr">Az összes még fel nem töltött szerkesztés vagy OSM-hiba megtalálható a %1$s. A már feltöltött pontok nem láthatók az OsmAndban.</string>
|
||||
<string name="osm_edits_view_descr">Az összes még fel nem töltött szerkesztés vagy OSM-hiba megtalálható a %1$s helyen. A már feltöltött pontok nem láthatók az OsmAndban.</string>
|
||||
<string name="app_mode_osm">OSM</string>
|
||||
<string name="select_nav_icon_descr">Az ikon csak navigáció vagy mozgás közben lesz látható.</string>
|
||||
<string name="select_map_icon_descr">A térképikon csak a térképen jelenik meg, navigáció közben pedig navigációs ikonra vált.</string>
|
||||
|
|
|
@ -91,7 +91,6 @@ public abstract class BaseSettingsFragment extends PreferenceFragmentCompat impl
|
|||
|
||||
MAIN_SETTINGS(MainSettingsFragment.TAG, false, R.xml.settings_main_screen, R.layout.global_preference_toolbar),
|
||||
GLOBAL_SETTINGS(GlobalSettingsFragment.class.getName(), false, R.xml.global_settings, R.layout.global_preference_toolbar),
|
||||
DEVELOPMENT_SETTINGS(DevelopmentSettingsFragment.class.getName(), false, R.xml.development_settings, R.layout.global_preference_toolbar),
|
||||
CONFIGURE_PROFILE(ConfigureProfileFragment.class.getName(), true, R.xml.configure_profile, R.layout.profile_preference_toolbar_with_switch),
|
||||
PROXY_SETTINGS(ProxySettingsFragment.class.getName(), false, R.xml.proxy_preferences, R.layout.global_preferences_toolbar_with_switch),
|
||||
GENERAL_PROFILE(GeneralProfileSettingsFragment.class.getName(), true, R.xml.general_profile_settings, R.layout.profile_preference_toolbar_big),
|
||||
|
@ -110,7 +109,8 @@ public abstract class BaseSettingsFragment extends PreferenceFragmentCompat impl
|
|||
MULTIMEDIA_NOTES(MultimediaNotesFragment.class.getName(), true, R.xml.multimedia_notes, R.layout.profile_preference_toolbar_big),
|
||||
MONITORING_SETTINGS(MonitoringSettingsFragment.class.getName(), true, R.xml.monitoring_settings, R.layout.profile_preference_toolbar_big),
|
||||
LIVE_MONITORING(LiveMonitoringFragment.class.getName(), false, R.xml.live_monitoring, R.layout.global_preferences_toolbar_with_switch),
|
||||
ACCESSIBILITY_SETTINGS(AccessibilitySettingsFragment.class.getName(), true, R.xml.accessibility_settings, R.layout.profile_preference_toolbar_big);
|
||||
ACCESSIBILITY_SETTINGS(AccessibilitySettingsFragment.class.getName(), true, R.xml.accessibility_settings, R.layout.profile_preference_toolbar_big),
|
||||
DEVELOPMENT_SETTINGS(DevelopmentSettingsFragment.class.getName(), false, R.xml.development_settings, R.layout.global_preference_toolbar);
|
||||
|
||||
public final String fragmentName;
|
||||
public final boolean profileDependent;
|
||||
|
@ -697,6 +697,7 @@ public abstract class BaseSettingsFragment extends PreferenceFragmentCompat impl
|
|||
p.setKey(b.getId());
|
||||
p.setSummary(summary);
|
||||
p.setLayoutResource(layoutId);
|
||||
p.setIconSpaceReserved(true);
|
||||
return p;
|
||||
}
|
||||
|
||||
|
@ -710,6 +711,7 @@ public abstract class BaseSettingsFragment extends PreferenceFragmentCompat impl
|
|||
p.setTitle(title);
|
||||
p.setSummary(summary);
|
||||
p.setLayoutResource(layoutId);
|
||||
p.setIconSpaceReserved(true);
|
||||
return p;
|
||||
}
|
||||
|
||||
|
@ -724,6 +726,7 @@ public abstract class BaseSettingsFragment extends PreferenceFragmentCompat impl
|
|||
listPreference.setDialogTitle(title);
|
||||
listPreference.setEntries(names);
|
||||
listPreference.setEntryValues(values);
|
||||
listPreference.setIconSpaceReserved(true);
|
||||
|
||||
if (layoutId != 0) {
|
||||
listPreference.setLayoutResource(layoutId);
|
||||
|
|
|
@ -186,7 +186,6 @@ public class RouteParametersFragment extends BaseSettingsFragment implements OnP
|
|||
String title = getString(R.string.prefer_in_routing_title);
|
||||
String descr = getString(R.string.prefer_in_routing_descr);
|
||||
MultiSelectBooleanPreference preferRouting = createRoutingBooleanMultiSelectPref(PREFER_ROUTING_PARAMETER_PREFIX, title, descr, preferParameters);
|
||||
preferRouting.setIconSpaceReserved(true);
|
||||
screen.addPreference(preferRouting);
|
||||
}
|
||||
if (reliefFactorParameters.size() > 0) {
|
||||
|
@ -207,7 +206,6 @@ public class RouteParametersFragment extends BaseSettingsFragment implements OnP
|
|||
switchPreferenceEx.setIcon(getRoutingPrefIcon(p.getId()));
|
||||
switchPreferenceEx.setSummaryOn(R.string.shared_string_on);
|
||||
switchPreferenceEx.setSummaryOff(R.string.shared_string_off);
|
||||
switchPreferenceEx.setIconSpaceReserved(true);
|
||||
|
||||
screen.addPreference(switchPreferenceEx);
|
||||
} else {
|
||||
|
@ -222,7 +220,6 @@ public class RouteParametersFragment extends BaseSettingsFragment implements OnP
|
|||
ListPreferenceEx listPreferenceEx = (ListPreferenceEx) createListPreferenceEx(pref.getId(), p.getPossibleValueDescriptions(), svlss, title, R.layout.preference_with_descr);
|
||||
listPreferenceEx.setDescription(description);
|
||||
listPreferenceEx.setIcon(getRoutingPrefIcon(p.getId()));
|
||||
listPreferenceEx.setIconSpaceReserved(true);
|
||||
|
||||
screen.addPreference(listPreferenceEx);
|
||||
}
|
||||
|
|
|
@ -191,13 +191,11 @@ public class VoiceAnnouncesFragment extends BaseSettingsFragment {
|
|||
//AudioManager.USE_DEFAULT_STREAM_TYPE};
|
||||
|
||||
ListPreferenceEx audioStreamGuidance = createListPreferenceEx(settings.AUDIO_STREAM_GUIDANCE.getId(), streamTypes, streamIntTypes, R.string.choose_audio_stream, R.layout.preference_with_descr);
|
||||
audioStreamGuidance.setIconSpaceReserved(true);
|
||||
getPreferenceScreen().addPreference(audioStreamGuidance);
|
||||
}
|
||||
|
||||
private void setupInterruptMusicPref() {
|
||||
Preference interruptMusicPref = createSwitchPreference(settings.INTERRUPT_MUSIC, R.string.interrupt_music, R.string.interrupt_music_descr, R.layout.preference_switch_with_descr);
|
||||
interruptMusicPref.setIconSpaceReserved(true);
|
||||
getPreferenceScreen().addPreference(interruptMusicPref);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue