Done lesson 3.08
[Sunshine.git] / app / src / main / res / xml / pref_general.xml
1 <PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android"
2 android:layout_width="match_parent"
3 android:layout_height="match_parent"
4 >
5
6 <CheckBoxPreference
7 android:key="example_checkbox"
8 android:title="@string/pref_title_social_recommendations"
9 android:summary="@string/pref_description_social_recommendations"
10 android:defaultValue="true" />
11
12 <!-- NOTE: EditTextPreference accepts EditText attributes. -->
13 <!-- NOTE: EditTextPreference's summary should be set to its value by the activity code. -->
14 <EditTextPreference
15 android:key="@string/pref_location_key"
16 android:title="@string/pref_location_label"
17 android:defaultValue="@string/pref_location_default"
18 android:selectAllOnFocus="true"
19 android:singleLine="true"
20 android:maxLines="1" />
21
22 <!-- NOTE: Hide buttons to simplify the UI. Users can touch outside the dialog to
23 dismiss it. -->
24 <!-- NOTE: ListPreference's summary should be set to its value by the activity code. -->
25 <ListPreference
26 android:key="example_list"
27 android:title="@string/pref_title_add_friends_to_messages"
28 android:defaultValue="-1"
29 android:entries="@array/pref_example_list_titles"
30 android:entryValues="@array/pref_example_list_values"
31 android:negativeButtonText="@null"
32 android:positiveButtonText="@null" />
33
34 </PreferenceScreen>