List of usage examples for android.preference PreferenceCategory addItemFromInflater
public void addItemFromInflater(Preference preference)
From source file:de.azapps.mirakel.settings.custom_views.Settings.java
public static PreferenceScreen inflateHeaders(final @NonNull PreferenceScreen screen, final @NonNull OnItemClickedListener<Settings> onClick) { for (final Map.Entry<Integer, List<Settings>> id : all.entrySet()) { final PreferenceCategory cat = new PreferenceCategory(ctx); screen.addPreference(cat);/*www. j a v a 2s.c om*/ cat.setTitle(id.getKey()); for (final Settings setting : id.getValue()) { if (setting == DEV && !MirakelCommonPreferences.isEnabledDebugMenu()) { continue; } cat.addItemFromInflater(setting.getPreference(onClick)); } } return screen; }