Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit e9211d58 authored by Julia Reynolds's avatar Julia Reynolds Committed by Android (Google) Code Review
Browse files

Merge "DO NOT MERGE DND settings redesign" into pi-dev

parents a1c70443 cb6fe394
Loading
Loading
Loading
Loading
+4 −17
Original line number Diff line number Diff line
@@ -727,6 +727,10 @@
                <action android:name="android.settings.ZEN_MODE_SETTINGS" />
                <category android:name="android.intent.category.DEFAULT" />
            </intent-filter>
            <intent-filter android:priority="1">
                <action android:name="android.settings.ZEN_MODE_PRIORITY_SETTINGS" />
                <category android:name="android.intent.category.DEFAULT" />
            </intent-filter>
            <intent-filter>
                <action android:name="android.intent.action.MAIN" />
                <category android:name="android.intent.category.DEFAULT" />
@@ -752,23 +756,6 @@
            </intent-filter>
        </activity>

        <activity
            android:name="Settings$ZenModeBehaviorSettingsActivity"
            android:label="@string/zen_mode_behavior_settings_title"
            android:icon="@drawable/ic_settings_notifications"
            android:exported="true"
            android:taskAffinity="com.android.settings"
            android:parentActivityName="Settings">
            <intent-filter android:priority="1">
                <action android:name="android.settings.ZEN_MODE_PRIORITY_SETTINGS" />
                <category android:name="android.intent.category.DEFAULT" />
            </intent-filter>
            <meta-data android:name="com.android.settings.FRAGMENT_CLASS"
                android:value="com.android.settings.notification.ZenModeBehaviorSettings" />
            <meta-data android:name="com.android.settings.PRIMARY_PROFILE_CONTROLLED"
                android:value="true" />
        </activity>

        <activity
            android:name="Settings$ZenModeAutomationSettingsActivity"
            android:label="@string/zen_mode_automation_settings_title"
+63 −14
Original line number Diff line number Diff line
@@ -7223,24 +7223,23 @@
    <!--  Do not disturb: Subtitle for the Visual signals option to toggle on/off visual signals/alerts when the screen is on/when screen is off. [CHAR LIMIT=30] -->
    <string name="zen_mode_visual_signals_settings_subtitle">Allow visual signals</string>
    <!-- Do not disturb: restrict notifications title [CHAR LIMIT=60] -->
    <string name="zen_mode_restrict_notifications_screen_title">Restrict notifications</string>
    <!-- Do not disturb: zen settings screens category title [CHAR LIMIT=100] -->
    <string name="zen_mode_settings_category">When Do Not Disturb is turned on</string>
    <!-- Do not disturb: restrict notifications title [CHAR LIMIT=60] -->
    <string name="zen_mode_restrict_notifications_title">Notifications</string>
    <!-- Do not disturb: restrict notifications category title [CHAR LIMIT=100] -->
    <string name="zen_mode_restrict_notifications_category">When Do Not Disturb is turned on</string>
    <!-- Do not disturb: Mute notifications option [CHAR LIMIT=60] -->
    <string name="zen_mode_restrict_notifications_mute">Mute notifications</string>
    <string name="zen_mode_restrict_notifications_mute">Show notifications silently</string>
    <!-- Do not disturb:Mute notifications summary [CHAR LIMIT=NONE] -->
    <string name="zen_mode_restrict_notifications_mute_summary">Show notifications but mute sounds &amp; vibrations</string>
    <string name="zen_mode_restrict_notifications_mute_summary">Notifications will be muted</string>
    <!-- Do not disturb:Mute notifications footer [CHAR LIMIT=NONE] -->
    <string name="zen_mode_restrict_notifications_mute_footer">When new notifications arrive your phone won\u2019t make a sound or vibration</string>
    <string name="zen_mode_restrict_notifications_mute_footer">When notifications arrive, your phone won\u2019t make a sound or vibrate.</string>
    <!-- Do not disturb: Hide notifications option [CHAR LIMIT=60] -->
    <string name="zen_mode_restrict_notifications_hide">Hide &amp; mute notifications</string>
    <string name="zen_mode_restrict_notifications_hide">Hide notifications</string>
    <!-- Do not disturb: Hide notifications summary [CHAR LIMIT=NONE] -->
    <string name="zen_mode_restrict_notifications_hide_summary">Notifications will not appear at all</string>
    <string name="zen_mode_restrict_notifications_hide_summary">You won\u2019t see new or existing notifications</string>
    <!-- Do not disturb: Hide notifications footer [CHAR LIMIT=NONE] -->
    <string name="zen_mode_restrict_notifications_hide_footer">You won\u2019t see new or existing notifications when Do Not Disturb is on. However, notifications needed for basic phone activity and status will still appear.</string>
    <string name="zen_mode_restrict_notifications_hide_footer">Your phone won\u2019t show new or existing notifications, and won\u2019t make a sound or vibrate. Notifications won\u2019t appear when you swipe down from the top of your screen.\n\nKeep in mind, critical notifications for phone activity and status will still appear.</string>
    <!-- Do not disturb: Custom settings option [CHAR LIMIT=60] -->
    <string name="zen_mode_restrict_notifications_custom">Custom</string>
    <!-- Do not disturb: restrict notifications page, menu option [CHAR LIMIT=60] -->
@@ -7360,6 +7359,35 @@
        <item quantity="other"><xliff:g id="on_count" example="3">%d</xliff:g> rules can turn on automatically</item>
    </plurals>
    <!-- Do not disturb settings, category header [CHAR LIMIT=100]-->
    <string name="zen_category_behavior">Behavior</string>
    <!-- Do not disturb settings, category header [CHAR LIMIT=100]-->
    <string name="zen_category_exceptions">Exceptions</string>
    <!-- Do not disturb settings, category header [CHAR LIMIT=100]-->
    <string name="zen_category_schedule">Schedule</string>
    <!-- Do not disturb settings, sound and vibrations title [CHAR LIMIT=100]-->
    <string name="zen_sound_title">Sound &amp; vibration</string>
    <!-- Do not disturb settings, sound and vibrations screen footer [CHAR LIMIT=NONE]-->
    <string name="zen_sound_footer">When Do Not Disturb is on, sound and vibration will be muted, except for the items you allow above.</string>
    <!-- Do not disturb settings, sound and vibrations screen category [CHAR LIMIT=100]-->
    <string name="zen_sound_category_title">Mute all except</string>
    <!-- Do not disturb settings, sound and vibrations summary [CHAR LIMIT=100]-->
    <string name="zen_sound_all_muted">Muted</string>
    <!-- Do not disturb settings, sound and vibrations summary [CHAR LIMIT=100]-->
    <string name="zen_sound_none_muted">Not muted</string>
    <!-- Do not disturb settings, sound and vibrations summary [CHAR LIMIT=100]-->
    <string name="zen_sound_one_allowed">Muted, but allow <xliff:g id="sound_type" example="alarms">%1$s</xliff:g></string>
    <!-- Do not disturb settings, sound and vibrations summary [CHAR LIMIT=100]-->
    <string name="zen_sound_two_allowed">Muted, but allow <xliff:g id="sound_type" example="alarms">%1$s</xliff:g> and <xliff:g id="sound_type" example="media">%2$s</xliff:g></string>
    <!-- Do not disturb settings, sound and vibrations summary [CHAR LIMIT=100]-->
    <string name="zen_sound_three_allowed">Muted, but allow <xliff:g id="sound_type" example="alarms">%1$s</xliff:g>, <xliff:g id="sound_type" example="alarms">%2$s</xliff:g>, and <xliff:g id="sound_type" example="media">%3$s</xliff:g></string>
    <!-- Do not disturb settings, messages, events and reminders title [CHAR LIMIT=100]-->
    <string name="zen_msg_event_reminder_title">Messages, events &amp; reminders</string>
    <!-- Do not disturb settings, messages, events and reminders footer [CHAR LIMIT=NONE]-->
    <string name="zen_msg_event_reminder_footer">When Do Not Disturb is on, messages, reminders, and events will muted, except for the items you allow above. You can adjust messages settings to allow your friends, family, or other contacts to reach you.</string>
    <!-- Do not disturb onboarding dialog, accept new settings [CHAR LIMIT=30]-->
    <string name="zen_onboarding_ok">Update</string>
    <!-- Do not disturb onboarding dialog, do not accept new settings [CHAR LIMIT=30]-->
@@ -7891,14 +7919,17 @@
    <!-- [CHAR LIMIT=20] Zen mode settings: Calls option -->
    <string name="zen_mode_calls">Calls</string>
    <!-- [CHAR LIMIT=20] Zen mode settings: Calls screen footer -->
    <string name="zen_mode_calls_footer">When Do Not Disturb is on, incoming calls are blocked. You can adjust settings to allow your friends, family, or other contacts to reach you.</string>
    <!-- [CHAR LIMIT=20] Zen mode settings: Messages option -->
    <string name="zen_mode_messages">Messages</string>
    <!-- [CHAR LIMIT=50] Zen mode settings: All messages summary -->
    <string name="zen_mode_all_messages">All messages</string>
    <string name="zen_mode_all_messages">Messages</string>
    <!-- [CHAR LIMIT=50] Zen mode settings: Selected messages summary -->
    <string name="zen_mode_selected_messages">Selected messages</string>
    <string name="zen_mode_selected_messages">Some messages</string>
    <!-- [CHAR LIMIT=40] Zen mode settings: Calls or messages option value: From anyone -->
    <string name="zen_mode_from_anyone">From anyone</string>
@@ -7909,6 +7940,15 @@
    <!-- [CHAR LIMIT=40] Zen mode settings: Calls or messages option value: From starred contacts only -->
    <string name="zen_mode_from_starred">From starred contacts only</string>
    <!-- Do not disturb settings, calls summary [CHAR LIMIT=100]-->
    <string name="zen_calls_summary_starred_repeat">From starred contacts and repeat callers</string>
    <!-- Do not disturb settings, calls summary [CHAR LIMIT=100]-->
    <string name="zen_calls_summary_contacts_repeat">From contacts and repeat callers</string>
    <!-- Do not disturb settings, calls summary [CHAR LIMIT=100]-->
    <string name="zen_calls_summary_repeat_only">From repeat callers only</string>
    <!-- [CHAR LIMIT=40] Zen mode settings: Calls or messages option value: None -->
    <string name="zen_mode_from_none">None</string>
@@ -7928,14 +7968,23 @@
    <string name="zen_mode_events">Events</string>
    <!-- [CHAR LIMIT=50] Zen mode settings: All callers summary -->
    <string name="zen_mode_all_callers">All callers</string>
    <string name="zen_mode_all_callers">anyone</string>
    <!-- [CHAR LIMIT=50] Zen mode settings: Selected callers summary -->
    <string name="zen_mode_contacts_callers">contacts</string>
    <!-- [CHAR LIMIT=50] Zen mode settings: Selected callers summary -->
    <string name="zen_mode_selected_callers">Selected callers</string>
    <string name="zen_mode_starred_callers">starred contacts</string>
    <!-- [CHAR LIMIT=50] Zen mode settings: Repeat callers option -->
    <string name="zen_mode_repeat_callers">Repeat callers</string>
    <!-- [CHAR LIMIT=50] Zen mode settings: calls summary -->
    <string name="zen_mode_calls_summary_one">From <xliff:g id="caller type" example="contacts">%1$s</xliff:g> only</string>
    <!-- [CHAR LIMIT=50] Zen mode settings: calls summary -->
    <string name="zen_mode_calls_summary_two">From <xliff:g id="caller type" example="starred contacts">%1$s</xliff:g> and <xliff:g id="callert tpye" example="repeat callers">%2$s</xliff:g></string>
    <!-- [CHAR LIMIT=200] Zen mode settings: Repeat callers option summary -->
    <string name="zen_mode_repeat_callers_summary">If the same person calls a second time within a <xliff:g id="minutes">%d</xliff:g> minute period</string>
+42 −0
Original line number Diff line number Diff line
<?xml version="1.0" encoding="utf-8"?>
<!--
     Copyright (C) 2017 The Android Open Source Project
     Copyright (C) 2018 The Android Open Source Project

     Licensed under the Apache License, Version 2.0 (the "License");
     you may not use this file except in compliance with the License.
@@ -17,42 +17,11 @@

<PreferenceScreen
    xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:settings="http://schemas.android.com/apk/res-auto"
    android:key="zen_mode_behavior_settings_page"
    android:title="@string/zen_mode_behavior_settings_title" >

   <!-- Alarms -->
   <SwitchPreference
       android:key="zen_mode_alarms"
       android:title="@string/zen_mode_alarms"/>

   <!-- Media -->
   <SwitchPreference
       android:key="zen_mode_media"
       android:title="@string/zen_mode_media"/>

   <!-- System -->
   <SwitchPreference
       android:key="zen_mode_system"
       android:title="@string/zen_mode_system"/>

   <!-- Reminders -->
   <SwitchPreference
       android:key="zen_mode_reminders"
       android:title="@string/zen_mode_reminders"/>

   <!-- Events -->
   <SwitchPreference
       android:key="zen_mode_events"
       android:title="@string/zen_mode_events"/>

   <!-- Messages -->
   <ListPreference
       android:key="zen_mode_messages"
       android:title="@string/zen_mode_messages"
       android:entries="@array/zen_mode_contacts_entries"
       android:entryValues="@array/zen_mode_contacts_values"/>
    android:key="zen_mode_calls_settings_page"
    android:title="@string/zen_mode_calls" >

   <PreferenceCategory
       android:title="@string/zen_mode_settings_category">
      <!-- Calls -->
      <ListPreference
          android:key="zen_mode_calls"
@@ -60,10 +29,13 @@
          android:entries="@array/zen_mode_contacts_entries"
          android:entryValues="@array/zen_mode_contacts_values"/>

      <!-- TODO: setting that links to contacts or placeholder for external app -->

      <!-- Repeat callers -->
      <SwitchPreference
          android:key="zen_mode_repeat_callers"
          android:title="@string/zen_mode_repeat_callers" />
   </PreferenceCategory>

   <com.android.settingslib.widget.FooterPreference/>

+45 −0
Original line number Diff line number Diff line
<?xml version="1.0" encoding="utf-8"?>
<!--
     Copyright (C) 2018 The Android Open Source Project

     Licensed under the Apache License, Version 2.0 (the "License");
     you may not use this file except in compliance with the License.
     You may obtain a copy of the License at

          http://www.apache.org/licenses/LICENSE-2.0

     Unless required by applicable law or agreed to in writing, software
     distributed under the License is distributed on an "AS IS" BASIS,
     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     See the License for the specific language governing permissions and
     limitations under the License.
-->

<PreferenceScreen
    xmlns:android="http://schemas.android.com/apk/res/android"
    android:key="zen_mode_msg_event_reminder_settings_page"
    android:title="@string/zen_msg_event_reminder_title" >

   <PreferenceCategory
      android:title="@string/zen_mode_settings_category">
      <!-- Messages -->
      <ListPreference
          android:key="zen_mode_messages"
          android:title="@string/zen_mode_messages"
          android:entries="@array/zen_mode_contacts_entries"
          android:entryValues="@array/zen_mode_contacts_values"/>

      <!-- Reminders -->
      <SwitchPreference
          android:key="zen_mode_reminders"
          android:title="@string/zen_mode_reminders"/>

      <!-- Events -->
      <SwitchPreference
          android:key="zen_mode_events"
          android:title="@string/zen_mode_events"/>
   </PreferenceCategory>

   <com.android.settingslib.widget.FooterPreference />

</PreferenceScreen>
+2 −2
Original line number Diff line number Diff line
@@ -18,11 +18,11 @@
<PreferenceScreen
    xmlns:android="http://schemas.android.com/apk/res/android"
    android:key="zen_mode_restrict_settings_page"
    android:title="@string/zen_mode_restrict_notifications_screen_title">
    android:title="@string/zen_mode_restrict_notifications_title">

    <PreferenceCategory
        android:key="restrict_category"
        android:title="@string/zen_mode_restrict_notifications_category">
        android:title="@string/zen_mode_settings_category">
        <com.android.settings.notification.ZenCustomRadioButtonPreference
            android:key="zen_mute_notifications"
            android:title="@string/zen_mode_restrict_notifications_mute"
Loading