Listview is similar to Google play setting activity in Android
                                        
                    •
                    Android                                    
                I want to create a list view like this:
Who knows what I should do?
resolvent:
You can set the "reference clip". It contains the hierarchy of preference objects displayed on the screen in the list. These preferences will be automatically saved as SharedPreferences when users interact with them
Defined in XML
<PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
<PreferenceCategory
    android:title="@string/title_first_section">
    <Check@R_411_2419@Preference
        android:key="check@R_411_2419@_preference"
        android:title="@string/title_check@R_411_2419@_preference"
        android:defaultValue="@string/default_check@R_411_2419@_preference"/>
    <EditTextPreference
        android:key="edittext_preference"
        android:title="@string/title_edittext_preference"
        android:summary="@string/summary_edittext_preference"
        android:dialogTitle="@string/dialog_title_edittext_preference"
        android:dependency="check@R_411_2419@_preference" />
    </PreferenceCategory>
<PreferenceCategory
    android:title="@string/title_second_section">
    <ListPreference
        android:key="list_preference"
        android:title="@string/title_list_preference"
        android:dialogTitle="@string/dialog_title_list_preference"
        android:entries="@array/entries_list_preference"
        android:entryValues="@array/entryvalues_list_preference" />
    <Preference
        android:title="@string/title_intent_preference">
        <intent android:action="android.intent.action.VIEW"
            android:data="http://codepath.com/" />
    </Preference>
    </PreferenceCategory>
You can refer to this https://github.com/codepath/android_ guides/wiki/Settings-with-PreferenceFragment
                            The content of this article comes from the network collection of netizens. It is used as a learning reference. The copyright belongs to the original author.
                        
                                            
                        THE END
                    
                    
                    
                                                        二维码
                        
                        
                                                
                        