1<?xml version="1.0" encoding="utf-8"?>
2<!--
3/*
4 * Copyright (C) 2011 The Android Open Source Project
5 *
6 * Licensed under the Apache License, Version 2.0 (the "License");
7 * you may not use this file except in compliance with the License.
8 * You may obtain a copy of the License at
9 *
10 *      http://www.apache.org/licenses/LICENSE-2.0
11 *
12 * Unless required by applicable law or agreed to in writing, software
13 * distributed under the License is distributed on an "AS IS" BASIS,
14 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15 * See the License for the specific language governing permissions and
16 * limitations under the License.
17 */
18-->
19<PreferenceScreen
20    xmlns:android="http://schemas.android.com/apk/res/android"
21    xmlns:app="http://schemas.android.com/apk/res-auto">
22
23    <Preference android:key="alerts_header"
24                android:summary="@string/alerts_header_summary"
25                android:selectable="false" />
26
27    <SwitchPreference android:defaultValue="@bool/master_toggle_enabled_default"
28                      android:key="enable_alerts_master_toggle"
29                      android:summary="@string/enable_alerts_master_toggle_summary"
30                      android:title="@string/enable_alerts_master_toggle_title" />
31
32    <!-- Settings to enable / disable emergency alerts -->
33    <PreferenceCategory android:title="@string/emergency_alerts_title"
34                        android:key="category_emergency_alerts">
35
36        <!-- Enable emergency alerts -->
37        <SwitchPreference android:defaultValue="@bool/emergency_alerts_enabled_default"
38                          android:key="enable_emergency_alerts"
39                          android:summary="@string/enable_emergency_alerts_message_summary"
40                          android:title="@string/enable_emergency_alerts_message_title" />
41
42        <!-- Show checkbox for Presidential alerts in settings -->
43        <SwitchPreference android:defaultValue="true"
44                          android:enabled="false"
45                          android:key="enable_cmas_presidential_alerts"
46                          android:summary="@string/enable_cmas_presidential_alerts_summary"
47                          android:title="@string/enable_cmas_presidential_alerts_title"/>
48
49        <!-- Enable CMAS Extreme Threat alerts -->
50        <SwitchPreference android:defaultValue="@bool/extreme_threat_alerts_enabled_default"
51                          android:key="enable_cmas_extreme_threat_alerts"
52                          android:summary="@string/enable_cmas_extreme_threat_alerts_summary"
53                          android:title="@string/enable_cmas_extreme_threat_alerts_title" />
54
55        <!-- Enable CMAS Severe Threat alerts -->
56        <SwitchPreference android:defaultValue="@bool/severe_threat_alerts_enabled_default"
57                          android:key="enable_cmas_severe_threat_alerts"
58                          android:summary="@string/enable_cmas_severe_threat_alerts_summary"
59                          android:title="@string/enable_cmas_severe_threat_alerts_title" />
60
61        <!-- Enable CMAS AMBER alerts -->
62        <SwitchPreference android:defaultValue="@bool/amber_alerts_enabled_default"
63                          android:key="enable_cmas_amber_alerts"
64                          android:summary="@string/enable_cmas_amber_alerts_summary"
65                          android:title="@string/enable_cmas_amber_alerts_title" />
66
67        <!-- Enable public safety messages -->
68        <SwitchPreference android:defaultValue="@bool/public_safety_messages_enabled_default"
69                          android:key="enable_public_safety_messages"
70                          android:summary="@string/enable_public_safety_messages_summary"
71                          android:title="@string/enable_public_safety_messages_title" />
72
73        <!-- Enable state/local test alerts -->
74        <SwitchPreference android:defaultValue="@bool/state_local_test_alerts_enabled_default"
75                          android:key="enable_state_local_test_alerts"
76                          android:summary="@string/enable_state_local_test_alerts_summary"
77                          android:title="@string/enable_state_local_test_alerts_title" />
78
79        <!-- Enable other test alerts -->
80        <SwitchPreference android:defaultValue="@bool/test_alerts_enabled_default"
81                          android:key="enable_test_alerts"
82                          android:summary="@string/enable_cmas_test_alerts_summary"
83                          android:title="@string/enable_cmas_test_alerts_title" />
84
85        <!-- Default value is true for Brazil and India. This preference is ignored and hidden
86        unless the boolean "config_showAreaUpdateInfoSettings" is set to true in the global resource. -->
87        <SwitchPreference android:defaultValue="@bool/area_update_info_alerts_enabled_default"
88                          android:key="enable_area_update_info_alerts"
89                          android:summary="@string/enable_area_update_info_alerts_summary"
90                          android:title="@string/enable_area_update_info_alerts_title" />
91
92        <Preference android:key="emergency_alert_history"
93                    android:title="@string/emergency_alert_history_title" />
94
95    </PreferenceCategory>
96
97
98    <!-- Settings of how alerts are shown to user. -->
99    <PreferenceCategory android:title="@string/alert_preferences_title"
100                        android:key="category_alert_preferences">
101
102        <SwitchPreference android:defaultValue="true"
103                          android:key="enable_alert_vibrate"
104                          android:title="@string/enable_alert_vibrate_title" />
105
106        <ListPreference android:key="alert_reminder_interval"
107                        android:title="@string/alert_reminder_interval_title"
108                        android:entries="@array/alert_reminder_interval_entries"
109                        android:entryValues="@array/alert_reminder_interval_values"
110                        android:defaultValue="@string/alert_reminder_interval_in_min_default"
111                        android:dialogTitle="@string/alert_reminder_dialog_title" />
112
113        <!-- Show additional language on/off switch in settings -->
114        <SwitchPreference android:defaultValue="false"
115                          android:key="receive_cmas_in_second_language"
116                          android:summary="@string/receive_cmas_in_second_language_summary"
117                          android:title="@string/receive_cmas_in_second_language_title" />
118
119        <SwitchPreference android:defaultValue="@bool/override_dnd_default"
120                          android:key="override_dnd"
121                          android:summary="@string/override_dnd_summary"
122                          android:title="@string/override_dnd_title" />
123    </PreferenceCategory>
124</PreferenceScreen>
125